Skip to content

Releases: weecology/portalcasting

hookup to zenodo

11 Jul 20:53
0e6f2bd
Compare
Choose a tag to compare

identical to v0.8.0 release
just created to trigger the integration with zenodo

v0.8.0

21 Mar 20:44
27b1a1d
Compare
Choose a tag to compare

plot_cov_RMSE_mod_spp now only plots the most recent -cast by default

  • If cast_dates = NULL (the default), the plot only uses the most recent -cast
    to avoid swamping more current -casts with historic -casts.

Added specific checks for no casts returned in plot functions

  • There's a bit of leeway with respect to argument validity, in particular around
    model names (to facilitate users making new models with new names, we don't want
    to hardwire a naming scheme in check_arg), so now there are checks to see if
    the tables returned from select_casts have any rows or not.

Handling the edge cases in model function testing

  • The trimming of the data sets for model function testing (happens in the AutoArima
    test script) now includes addition of some dummy values for edge cases (all 0
    observations and nearly-all-0 observations), which allows better coverage of testing
    for the -GARCH model functions in particular.

v0.7.0

21 Mar 09:09
2000646
Compare
Choose a tag to compare

Addressing nbGARCH and nbsGARCH when even the Poisson fallback fails

  • In nbGARCH and then extended into nbsGARCH, the models fall back
    to a Poisson distribution if the negative binomial fit fails. Previously
    (with only nbGARCH) the Poisson fit always succeeded in those back-ups,
    but now (with nbsGARCH) that sometimes isn't the case (because the predictor
    model is more complex) and even the Poisson fit can fail. So now for both
    models, if that fit fails, we follow what occurs in pevGARCH which is to
    use the fcast0 forecast of 0s and an arbitrarily high AIC (1e6).

v0.6.0

20 Mar 16:04
af112b9
Compare
Choose a tag to compare

Addressing covariate forecasts in pevGARCH under hindcasting

  • pevGARCH() was not set up to leverage the covariate_forecasts file.
  • It's now set up with a toggle based on the cast_type in the metadata list
    (which has replaced the formerly named filename_suffix element) to load
    the covariate_forecasts file (using a new read_covariate_forecasts function)
    and then select the specific hindcast based on the source and date_made columns
    as selected by new elements in the metadata list (covariate_source and
    covariate_date_made).

v0.5.0

20 Mar 02:11
8b40857
Compare
Choose a tag to compare

Adding nbsGARCH

  • Model nbsGARCH has been added to the base set of models.

foy function

  • foy() calculates the fraction of the year for a given date or set
    of dates.

v0.4.1

20 Mar 00:10
0902204
Compare
Choose a tag to compare

Move to usage of CRAN portalr

model_scripts function

  • Provides a simple way to list the scripts in the models subdirectory.

Including the package version message in setup_dir and portalcast

  • Including a simple message to report the version of portalcasting
    loaded in top level functions.

Vignette updates

  • Adding plot (from pre-constructed images) to the how-to vignette.

Patching a bug in model_template

  • There was a lingering old name from the argument switch over that was
    causing model templates to be written with a "" argument for the model
    model name input into save_forecast_output.

v0.4.0

16 Mar 21:14
b051059
Compare
Choose a tag to compare

Tidied functionality for checking function arguments

  • Introduction of check_args and check_arg which collaborate to
    check the validity of function arguments using a standardized set
    of requirments based on the argument names, thereby helping to unify
    and standardize the use of the codebase's arguments.
  • This is a much more robust and generalized function than
    check_options_args() was.

Updated function names

  • prep_rodents is now prep_rodents_list
  • rodents_data is now prep_rodents
  • update_rodents is now update_rodents_list
  • read_data has been split out into read_all, read_controls,
    read_covariates, read_moons, and read_metadata
  • model_path is now model_paths
  • sub_path and sub_paths have been merged into sub_paths, which
    returns all if specific_subs is NULL
  • lag_data is now lag_covariates

Updated argument (names to leverage check_args, etc.)

  • In multiple functions data has been replaced with rodents to be
    specific.
  • CI_level is now subsumed by confidence_level
  • name is now subsumed by model
  • set is not split into species_set and model_set
  • The order of arguments in model_names is now back to model_set,
    add.
  • The default subs_type for subdirs is now "portalcasting".
  • The four model functions have a reduced set of inputs to leverage the
    directory tree, and the script generation is updated to match.
  • Updating the cast argument to cast_to_check in cast_is_valid and
    removing the verbose argument from verify_cast to allow check_arg to
    leverage check_arg for verify_cast.

Removal of classes

  • The models class has been removed.
  • The subdirs class has been removed.

messageq function

  • messageq function is added to tidy code around messages being printed
    based on the quiet arguments.

Inclusion of "wEnsemble" as an option in model_names

  • Produces the prefab list with an "Ensemble" entry added, to allow for
    that simply without using the NULL options, which collects all model names.
  • This facilitated addition of models as an argument in the evaluations
    plots.

v0.3.0

05 Mar 01:35
20715f0
Compare
Choose a tag to compare

Completed migration of plotting code

  • plot_cast is now plot_cast_ts and is now fully vetted and tested
  • plotcastts_ylab and plotcastts_xaxis provide tidied functions for
    producing the y label and x axis (respectively) for plot_cast_ts.
  • plot_cast_point is now added to replace plot_species_forecast.
  • plotcastpoint_yaxis provides tidied functionality for the y axis of
    plot_cast_point.
  • select_most_ab_spp allows for a simple selection of the most abundant
    species from a -cast.
  • plot_err_lead_spp_mods and plot_cov_RMSE_mod_spp now added to
    replace the raw code in the evaluation page.

Processing of forecasts

  • read_casts (old) is now read_cast and specifically works for only one -cast.
  • read_casts (new) reads in multiple -casts.
  • select_cast is now select_casts and allows a more flexible selection
    by default.
  • make_ensemble now returns a set of predictions with non-NA bounds when
    only one model is included (it returns that model as the ensemble).
  • most_recent_cast returns the date of the most recent -cast. Can be dependent
    on the presence of a census.
  • verify_cast and cast_is_valid replace forecast_is_valid from the
    repo codebase. verify_cast is a logical wrapper on cast_is_valid that
    facilitates a pipeline integration. cast_is_valid does the major set of
    checks of the cast data frame.
  • append_observed_to_cast is provided to add the observed data to the forecasts
    and add columns for the raw error, in-forecast-window, and lead time as well.
  • measure_cast_error allows for summarization of errors at the -cast level.

Processing of data

  • most_recent_census returns the date of the most recent census.

Minor changes

  • Argument order in models is reversed (add then set) and defaults in general
    are now NULL and NULL, but set = "prefab" within the options functions, to
    make it easy to run a novel model set.
  • Argument order in subdirs is reversed (subs then type) and defaults in
    general are now NULL and NULL, but type = "portalcasting" within options
    functions and dirtree to make it easier to manage a single subdirectory.
  • fdate argument has been replaced throughout with cast_date for generality.

Utilities

  • na_conformer provides tidy functionality for converting non-character NA
    entries (can get read in from the data due to the "NA" species) to "NA".
    Works for both vectors and data frames.