4 Estimation - merrillrudd/LIME GitHub Wiki
Estimation
Using LIME for estimation requires three vital steps:
- Setup data correctly
- Run the LIME model using TMB
- Check convergence and plot output
- Run sensitivities
Data setup
It is very important that the data are set up correctly for the LIME estimation to run.
Length data
A matrix with the time step (e.g. year) along the rows and length bins along the columns.
- Rows should be named with the year names. Only years with length data should be included. Years can be in true years (1998-2017) or indexed years (1-20) as long as there is consistency between items in the data list (see "Input List" below).
- Columns should be named with the upper length bins. Columns should range from the first possible length bin (e.g. 1 for 1-cm length bins) to the last observed length bin. If there are no observations until 30cm, add a matrix of zeros for lengths 1,2,3,...29cm. If the last observed length bin is less than 1.5 times the asymptotic length (linf), LIME will internally add a matrix of zeros to be able to account for potentially larger fish than were observed.
## years with length data -- rename with your own years with length data
length_years <- rownames(true$LF)
## length bins -- rename with your upper length bins
length_bins <- colnames(true$LF)
## matrix with length frequency data
LF <- true$LF
## set rownames as years
rownames(LF) <- length_years
## set colnames as length bins
colnames(LF) <- length_bins
## first six years of length data
head(LF)