prodASPM: prodASPM summarizes ASPM statistics and plots the...

View source: R/aspm.r

prodASPMR Documentation

prodASPM summarizes ASPM statistics and plots the productivity

Description

prodASPM summarizes ASPM statistics and plots the productivity. The statistics it returns are the MSY, Bmsy, Hmsy (harvest rate that leads at equilibrium to MSY), Dmsy (the depletion level at which MSY occurs, and the predicted B0). These are printed to the console if the parameter 'console' is set to TRUE. In addition, a plot of the production curve, (yield vs Spawning Biomass), yield vs Harvest Rate, and yield vs Depletion level is produced if the parameter plot is set to TRUE

Usage

prodASPM(inprod, target = 0.48, console = TRUE, plot = TRUE)

Arguments

inprod

The production matrix generated by getProductionC

target

in addition to the MSY what biomass target, in terms of target x B0 is wanted. Default = 0.48

console

print the results directly to the console; default = TRUE

plot

plot the yield vs Spawning biomass, harvest rate, and depletion. defaults to TRUE.

Value

a vector containing seven output statistics. It also prints to the console and plots the results if those parameters are set TRUE

Examples

## Not run: 
data(fishdat)
fish <- fishdat$fish
glb <- fishdat$glb
props <- fishdat$props
pars <- c(14,0.3)
bestL <- optim(pars,aspmLL,method="Nelder-Mead",infish=fish,inglb=glb,
               inprops=props,control=list(maxit=1000,parscale=c(10,0.1)))
prod <- getProduction(exp(bestL$par[1]),infish=fish,inglb=glb,inprops=props,
                      Hrg=c(0.0005,0.07,0.0005),nyr=50)
 plotprep(width=7,height=6)
spsprod <- prodASPM(prod, console=TRUE, plot=TRUE)

## End(Not run)

haddonm/datalowSA documentation built on Nov. 5, 2023, 6:40 p.m.