MatCount:
Build Databases for Sexual Maturity Modeling by Logistic Regression
Description
From a data.frame of one continuous predictor (length, age, etc), and keys for
ordinal precictor sex, month, and maturity stage, this function will builds a list
of variable ready to be used in a 2- or 3-parameter logistic model
A data.frame where each row is an individual fish, and the columns are a
continuous predictor, and ordinal keys for sex, month, and maturity stage
fem.key
Integer, the ordinal key identifying females
mal.key
Integer, the ordinal key identifying males
stage.key
Integer, the ordinal key identifying the last maturity stage of juveniles. This
key will split the individual into immature (all having stage
season.key
Integer vector with two components, the first and last month of the reproductive
season
Value
mal.nrep
A data.frame with the continuous predictor duplicated and sorted,
a binary for mature individuals, a binary for juveniles, and the
count of males in the non reproductive season
mal.rep
A data.frame with the continuous predictor duplicated and sorted,
a binary for mature individuals, a binary for juveniles, and the
count of males in the reproductive season
fem.nrep
A data.frame with the continuous predictor duplicated and sorted,
a binary for mature individuals, a binary for juveniles, and the
count of females in the non reproductive season
fem.rep
A data.frame with the continuous predictor duplicated and sorted,
a binary for mature individuals, a binary for juveniles, and the
count of females in the reproductive season
Details
The year is divided into two seasons, the reproductive season and the
non-reproductive season
References
R. Roa, B. Ernst, F. Tapia. 1999. Estimation of size at sexual maturity: evaluation
of analytical and resampling procedures. Fishery Bulletin (US) 97:570-580.