plotCat | R Documentation |
Plot a summary of stock status categories by year: underfished (green), fully fished (yellow), or overfished (red).
plotCat(dat, method = "cmsy.naive", cats = 4, type = "count")
dat |
data frame of stock time series, containing columns named
|
method |
string indicating which method was used to estimate B/Bmsy and F/Fmsy. |
cats |
either |
type |
string indicating the type of plot, either |
The first two columns in dat
are treated as 'stock'
and
'year'
, regardless of the actual column names.
The last column names in dat
should contain the method
name as
a suffix. For example, if method = "effEdepP"
, then this function will
look for columns called bbmsy.effEdepP
and ffmsy.effEdepP
.
The type
argument supports legacy synonyms, where "prop"
is the
same as "count"
, and "all"
is the same as "stock"
.
A ggplot
object.
Rishi Sharma and Arni Magnusson.
ggplot
is the underlying function used to produce the plot.
calcCat
calculates stock status categories.
SOFIA-package
gives an overview of the package.
## Not run: plotCat(stock.timeseries, method="effEdepP", cats=3, type="count") plotCat(stock.timeseries, method="effEdepP", cats=3, type="stock") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.