| validateWs {FSA} | R Documentation |
The Willis and empirical quantiles (EmpQ) methods to assess length-bias in a proposed standard weight equation.
validateWs(object,df,pops,len,wt,min,max,w=10,type=c("EmpQ","Willis"),
n.cutoff=3,cutoff.tail=TRUE,qtype=8,probs=0.75,use.means=FALSE,
quadratic=TRUE,weighted=FALSE,alpha=0.05)
## S3 method for class 'WILLIS':
print(x,...)
## S3 method for class 'WILLIS':
summary(object,...)
## S3 method for class 'EMPQ':
anova(object,...)
## S3 method for class 'EMPQ':
coef(object,...)
## S3 method for class 'EMPQ':
summary(object,...)
## S3 method for class 'EMPQ':
predict(object, ...)
## S3 method for class 'EMPQ':
plot(x,pch=16,col.pt="black",xlab="Midpoint Length Category",
ylab=paste("Standardized",100*object$probs,"Percentile Mean Weight"),...)
## S3 method for class 'EMPQ':
fit.plot(object,pch=16,col.pt="black",col.mdl="red",lwd.mdl=3,
lty.mdl=1,xlab="Midpoint Length Category",
ylab=paste("Standardized",100*object$probs,"Percentile Mean Weight"),
main="EmpQ Method",...)
object |
An object of class RLP or EMP returned from calling rlp() or emp() in the main function and an object of class class EMPQ or WILLIS (saved from the validateWs) in the generic functions. |
df |
A data frame containing the length-weight data for each population. |
pops |
A string or numeric indicating which column in df contains the variable identifying the different populations. |
len |
A string or numeric indicating which column in df contains the variable with the length data. |
wt |
A string or numeric indicating which column in df contains the variable with the weight data. |
min |
A number indicating the midpoint value of the smallest X-mm length category. |
max |
A number indicating the midpoint value of the largest X-mm length category. |
w |
A number indicating the widths for which to create length categories. |
type |
A string indicating which type of bias detection method should be used. |
n.cutoff |
A numeric indicating the minimum sample size in a length category that should be included in the EmpQ regression. Ignored if type="Willis". |
cutoff.tail |
A logical indicating if all length categories larger than the lowest length category with a sample size below n.cutoff should be excluded =TRUE or just those length categories with sample sizes lower than n.cutoff. Ignored if type="Willis". |
qtype |
Type of quantile method to use. See details. Ignored if use.means=TRUE. |
probs |
A number indicating the probability of the quantile. Must be between 0 and 1. Ignored if use.means=TRUE. |
use.means |
A logical indicating whether mean mean weight rather than a quantile mean weight should be used in the EmpQ method. |
quadratic |
A logical indicating whether a quadratic regression should be fit in the EmpQ method. Ignored if type="Willis". |
weighted |
A logical indicating whether the regression in the EmpQ method should be weighted by the number of populations present in each length category. Ignored if type="Willis". |
alpha |
A numeric indicating the rejection criterion to be used in the Willis method. Ignored if type="EmpQ". |
x |
An object saved from the validateWs call (i.e., of class EMPQ or WILLIS). |
pch |
A single numeric indicating what plotting characther codes should be used for the points in plot or fit.plot. |
col.pt |
A string used to indicate the color of the plotted points. |
xlab |
A label for the x-axis of plot or fit.plot. |
ylab |
A label for the y-axis of plot or fit.plot. |
col.mdl |
A string indicating the type of color to use for the standard length-weight regression line. |
lwd.mdl |
A numeric indicating the width of the line to use for the standard length-weight regression line. |
lty.mdl |
A numeric indicating the type of line to use for the standard length-weight regression line. |
main |
A label for the main title of fit.plot. |
... |
Additional arguments for methods. |
The main function can be used to assess length-bias in a proposed standard weight equation using either the method of Willis et al. (1991) (i.e., type="Willis") or the empricial quantiles method of Gerow et al. (2004) (i.e., type="EmpQ"). The Willis method begins by regressing the relative weight computed from the candidate standard weight equation (supplied in object) for each individual in a population in the df data frame against length. This is repeated for each population in df. The number of positive and negative slopes from this regression that are statistically significant are counted and a chi-square test is used to determine if there is a statistically equal number of each. If there is a statistically equal number of positive and negative significant slopes then the standard weight equation is said not to exhibit a length bias.
The EmpQ method is performed by (1) computing the mean actual weight per w-mm length category for each population, (2) computing the given quartile (default is third) of mean actual weight per length category across all populations, (3) standardizing the quartile mean weights by dividing each by the standard weight for the midpoint of the length categories using the proposed standard weight equation, and (4) regressing the standardized quartile mean weights against the length category midpoints. The regression can either be quadratic (i.e., quadratic=TRUE) as proposed by Gerow et al. (2004) or n-weighted (i.e., weighted=TRUE). In addition, length categories with fewer than ncutoff are eliminated (see cutoff.tail description above). A slope of zero for the relationship between standardized quartile mean weights and length category midpoints indicates that no length-based biases exist with the proposed standard weight equation.
Types of quantile calculation methods are discussed in the details of of quantile.
If type="Willis" then a list is returned with six items. The first item (res.ind) is a data frame containing the results of the individual regressions. The second item (res.tbl) is the table summarizing the number of positive and negative significant slopes. The third item (res.test) contains the results for the chi-square test.
If type="EmpQ" then a list is returned with five items. The first item (n.by.pop) is a table of the number of populations represented in each length category. The second item (regdata) is a dataframe used for the EmpQ regression. The third item (quadratic) is a logical indicating whether the quadratic regression was used. The fourth item (weighted) is a logical indicating whether a weighted regression was used. The fifth item (lm.v) is the EmpQ regression model results.
Derek H. Ogle, dogle@northland.edu
Gerow, K.G., W.A. Hubert, R.C. Anderson-Sprecher. 2004. An alternative approach to detection of length-related biases in standard weight equations. North American Journal of Fisheries Management 24:903-910.
Willis, D.W., C.S. Guy, and B.R. Murphy. 1991. Development and evaluation of the standard weight (Ws) equation for yellow perch. North American Journal of Fisheries Management, 11:374-380.
## See examples in rlp(), emp(), and Froese()