Calculates the D statistic (sqrt of accumulated variance among ages; Lai 1987) for a range of age sample sizes using data from an age-length key. Assumes a two-stage random sampling design with proportional or fixed allocation.
alkD(x, lss = NULL, minss = NULL, maxss = NULL, sampint = NULL,
allocate = 1)
list element containing the summary of input criteria
list element containing the D statistic for each age sample size given lss
a data frame containing an age-length key (similar to Table 8.3 on page 307 of Quinn and Deriso (1999)). The first column must contain the length intervals as numeric labels (no ranges), the second column must contain the number of samples within each length interval (Ll in Q & D), and the third and remaining columns must contain the number of samples for each age class within each length interval (one column for each age class). Column labels are not necessary but are helpful. Columns l and Al in Table 8.3 should not be included. Empty cells must contain zeros.
the sample size for length frequency
the minimum age sample size
the maximum age sample size. Value can not be larger than the sample size for the length frequency(lss
)
the sample size interval
the type of allocation: 1=proportional, 2=fixed.
Gary A. Nelson, Massachusetts Division of Marine Fisheries gary.nelson@mass.gov
Following Quinn and Deriso (1999:pages 308-309), the function calculates the D statistic (sqrt of
accumulated variance among ages; Lai 1987) for a range of age sample sizes defined by minss
, maxss
, and
sampint
at a
given length sample size lss
. The size of an age sample at a desired level of D can be obtained by the comparison. See reference
to Table 8.8, p. 314 in Quinn and Deriso.
Quinn, T. J. and R. B. Deriso. 1999. Quantitative Fish Dynamics. Oxford University Press, New York, New York. 542 pages
Lai, H.L. 1987. Optimum allocation for estimating age composition using age-length keys. U.S. Fish. Bull. 85:179-185
alkss
alkprop
data(alkdata)
alkD(alkdata,lss=1000,minss=25,maxss=1000,sampint=20,allocate=1)
Run the code above in your browser using DataLab