Skip to contents

A total of 104 fish dispersed proportionately over 1-cm fork length intervals from the Morwong4 data frame was obtained for age assignment. The remaining fish in the file were only measured for length (i.e., the ages were deleted). This data file can be used to demonstrate the use of age-length keys.

Format

A data frame with 392 observations on the following 2 variables.

fl

Fork lengths (cm)

age

Assigned ages

Source

CSV file

Topic(s)

  • Age-Length Key

See also

Examples

data(Morwong4a)
str(Morwong4a)
#> 'data.frame':	392 obs. of  2 variables:
#>  $ fl : int  29 30 30 28 28 31 31 27 30 30 ...
#>  $ age: int  8 7 3 5 6 5 7 4 7 7 ...
head(Morwong4a)
#>   fl age
#> 1 29   8
#> 2 30   7
#> 3 30   3
#> 4 28   5
#> 5 28   6
#> 6 31   5

## extract aged sample
m4a.aged <- subset(Morwong4a,!is.na(age))
str(m4a.aged)
#> 'data.frame':	104 obs. of  2 variables:
#>  $ fl : int  29 30 30 28 28 31 31 27 30 30 ...
#>  $ age: int  8 7 3 5 6 5 7 4 7 7 ...

## extract length sample
m4a.length <- subset(Morwong4a,is.na(age))
str(m4a.length)
#> 'data.frame':	288 obs. of  2 variables:
#>  $ fl : int  30 31 26 31 30 30 31 30 28 25 ...
#>  $ age: int  NA NA NA NA NA NA NA NA NA NA ...