Plots modeled values as lines, observed values as points
Arguments
- DO_preds
a data.frame of predictions such as that returned by predict_DO()
- y_var
character. Should the plot display predicted & observed values in concentration (conc) or as percent of saturation (pctsat)? The default is to plot both.
- style
character indicating which graphics package to use
- y_lim
list of named vectors, each of which has length 2 and is numeric and has a name in the possible values of y_var. NA within a vector indicates that the data range should be used. for ggplot2, y_lim is only used to exclude values outside that range and is ignored if the data span a narrower range
- date_start
Date or a class convertible with as.Date. The first date (inclusive) for which to report DO predictions. If NA, no filtering is done.
- date_end
Date or a class convertible with as.Date. The last date (inclusive) for which to report DO predictions. If NA, no filtering is done.
- use_saved
logical. Is it OK to use predictions that were saved with the model?
Examples
if (FALSE) {
mm <- metab_night(specs(mm_name('night')), data=data_metab('3', day_start=12, day_end=36))
plot_DO_preds(mm)
plot_DO_preds(mm, date_start='2012-09-19', date_end='2012-09-19')
plot_DO_preds(mm, style='dygraphs', y_var='pctsat')
}