plot.bumbldf {bumbl} | R Documentation |
Creates one plot per level of colonyID showing the observed (points) and fitted (red line) values from the model implemented by bumbl()
.
## S3 method for class 'bumbldf'
plot(x, ..., colony = NULL)
x |
a dataframe produced by |
... |
other arguments not used by this method. |
colony |
optional vector of colony ID's (character) or indexes (numeric) to plot. If not supplied, all colonies will be plotted. |
invisibly returns a list of dataframes used for building the plots.
set.seed(687)
colonyID_subset <- sample(bombus$colony, 10)
colony_subset <- bombus[bombus$colony %in% colonyID_subset, ]
results <- bumbl(colony_subset, colonyID = colony, t = week,
formula = mass ~ week)
plot(results)