Skip to contents

mvgam 1.1.4 (development version; not yet on CRAN)

New functionalities

  • Added the how_to_cite.mvgam() function to generate a scaffold methods description of fitted models, which can hopefully make it easier for users to fully describe their programming environment
  • Improved various plotting functions by returning ggplot objects in place of base plots (thanks to @mhollanders #38)
  • Added the brier score (score = 'brier') as an option in score.mvgam_forecast() for scoring forecasts of binary variables when using family = bernoulli() (#80)
  • Added augment() function to add residuals and fitted values to an mvgam object’s observed data (thanks to @swpease #83)
  • Added support for approximate gp() effects with more than one covariate and with different kernel functions (#79)
  • Added function jsdgam() to estimate Joint Species Distribution Models in which both the latent factors and the observation model components can include any of mvgam’s complex linear predictor effects. Also added a function residual_cor() to compute residual correlation, covariance and precision matrices from jsdgam models. See ?mvgam::jsdgam and ?mvgam::residual_cor for details
  • Added a stability.mvgam() method to compute stability metrics from models fit with Vector Autoregressive dynamics (#21 and #76)
  • Added functionality to estimate hierarchical error correlations when using multivariate latent process models and when the data are nested among levels of a relevant grouping factor (#75); see ?mvgam::AR for an example
  • Added ZMVN() error models for estimating Zero-Mean Multivariate Normal errors; convenient for working with non time-series data where latent residuals are expected to be correlated (such as when fitting Joint Species Distribution Models); see ?mvgam::ZMVN for examples
  • Added a fevd.mvgam() method to compute forecast error variance decompositions from models fit with Vector Autoregressive dynamics (#21 and #76)

Deprecations

  • Arguments use_stan, jags_path, data_train, data_test, adapt_delta, max_treedepth and drift have been removed from primary functions to streamline documentation and reflect the package’s mission to deprecate ‘JAGS’ as a suitable backend. Both adapt_delta and max_treedepth should now be supplied in a named list() to the new argument control

Bug fixes

  • Updates to ensure ensemble provides appropriate weighting of forecast draws (#98)
  • Not necessarily a “bug fix”, but this update removes several dependencies to lighten installation and improve efficiency of the workflow (#93)
  • Fixed a minor bug in the way trend_map recognises levels of the series factor
  • Bug fix to ensure lfo_cv recognises the actual times in time, just in case the user supplies data that doesn’t start at t = 1. Also updated documentation to better reflect this
  • Bug fix to ensure update.mvgam captures any knots or trend_knots arguments that were passed to the original model call

mvgam 1.1.3

CRAN release: 2024-09-04

New functionalities

  • Allow intercepts to be included in process models when trend_formula is supplied. This breaks the assumption that the process has to be zero-centred, adding more modelling flexibility but also potentially inducing nonidentifiabilities with respect to any observation model intercepts. Thoughtful priors are a must for these models
  • Added standata.mvgam_prefit, stancode.mvgam and stancode.mvgam_prefit methods for better alignment with ‘brms’ workflows
  • Added ‘gratia’ to Enhancements to allow popular methods such as draw() to be used for ‘mvgam’ models if ‘gratia’ is already installed
  • Added an ensemble.mvgam_forecast() method to generate evenly weighted combinations of probabilistic forecast distributions
  • Added an irf.mvgam() method to compute Generalized and Orthogonalized Impulse Response Functions (IRFs) from models fit with Vector Autoregressive dynamics

Deprecations

  • The drift argument has been deprecated. It is now recommended for users to include parametric fixed effects of “time” in their respective GAM formulae to capture any expected drift effects

Bug fixes

  • Added a new check to ensure that exception messages are only suppressed by the silent argument if the user’s version of ‘cmdstanr’ is adequate
  • Updated dependency for ‘brms’ to version >= ‘2.21.0’ so that read_csv_as_stanfit can be imported, which should future-proof the conversion of ‘cmdstanr’ models to stanfit objects (#70)

mvgam 1.1.2

CRAN release: 2024-07-01

New functionalities

  • Added options for silencing some of the ‘Stan’ compiler and modeling messages using the silent argument in mvgam()
  • Moved a number of packages from ‘Depends’ to ‘Imports’ for simpler package loading and fewer potential masking conflicts
  • Improved efficiency of the model initialisation by tweaking parameters of the underlying ‘mgcv’ gam object’s convergence criteria, resulting in much faster model setups
  • Added an option to use trend_model = 'None' in State-Space models, increasing flexibility by ensuring the process error evolves as white noise (#51)
  • Added an option to use the non-centred parameterisation for some autoregressive trend models, which speeds up mixing most of the time
  • Updated support for multithreading so that all observation families (apart from nmix()) can now be modeled with multiple threads
  • Changed default priors on autoregressive coefficients (AR1, AR2, AR3) to enforce stationarity, which is a much more sensible prior in the majority of contexts

Bug fixes

mvgam 1.1.1

CRAN release: 2024-05-10

New functionalities

mvgam 1.1.0

CRAN release: 2024-05-06

  • First release of mvgam to CRAN