Package: ggsmc 0.1.2.0

ggsmc: Visualising Output from Sequential Monte Carlo Samplers and Ensemble-Based Methods

Functions for plotting, and animating, the output of importance samplers, sequential Monte Carlo samplers (SMC) and ensemble-based methods. The package can be used to plot and animate histograms, densities, scatter plots and time series, and to plot the genealogy of an SMC or ensemble-based algorithm. These functions all rely on algorithm output to be supplied in tidy format. A function is provided to transform algorithm output from matrix format (one Monte Carlo point per row) to the tidy format required by the plotting and animating functions.

Authors:Richard G Everitt [aut, cre]

ggsmc_0.1.2.0.tar.gz
ggsmc_0.1.2.0.zip(r-4.5)ggsmc_0.1.2.0.zip(r-4.4)ggsmc_0.1.2.0.zip(r-4.3)
ggsmc_0.1.2.0.tgz(r-4.4-any)ggsmc_0.1.2.0.tgz(r-4.3-any)
ggsmc_0.1.2.0.tar.gz(r-4.5-noble)ggsmc_0.1.2.0.tar.gz(r-4.4-noble)
ggsmc_0.1.2.0.tgz(r-4.4-emscripten)ggsmc_0.1.2.0.tgz(r-4.3-emscripten)
ggsmc.pdf |ggsmc.html
ggsmc/json (API)

# Install 'ggsmc' in R:
install.packages('ggsmc', repos = c('https://richardgeveritt.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/richardgeveritt/ggsmc/issues

Datasets:
  • cwna_data - Data generated from a constant velocity (or continuous white noise acceleration, CWNA) model for 20 time steps.
  • lv_output - 10000 simulations from a stochastic Lotka-Volterra model, assigned weights according to a Gaussian approximate Bayesian computation kernel with tolerance equal to 50.
  • mixture_25_particles - The output of an SMC sampler where the initial distribution is a Gaussian and the final target is a mixture of Gaussians. 25 particles were used, with an adaptive method to determine the sequence of targets, and a Metropolis-Hastings move to move the particles at each step.
  • sir_cwna_model - The output of a bootstrap particle filter on the 'cwna_data'. The output consists of 100 particles over 20 time steps.

On CRAN:

4.60 score 5 scripts 465 downloads 11 exports 50 dependencies

Last updated 2 months agofrom:0f3f579b43. Checks:OK: 3 NOTE: 4. Indexed: yes.

TargetResultDate
Doc / VignettesOKOct 29 2024
R-4.5-winOKOct 29 2024
R-4.5-linuxOKOct 29 2024
R-4.4-winNOTEOct 29 2024
R-4.4-macNOTEOct 29 2024
R-4.3-winNOTEOct 29 2024
R-4.3-macNOTEOct 29 2024

Exports:animate_densityanimate_histogramanimate_reveal_time_seriesanimate_scatteranimate_time_seriesmatrix2tidyplot_densityplot_genealogyplot_histogramplot_scatterplot_time_series

Dependencies:classclassIntclicolorspacecpp11crayonDBIe1071fansifarvergganimateggplot2gluegtablehmsisobandKernSmoothlabelinglatticelifecyclelpSolvemagrittrMASSMatrixmgcvmunsellnlmepillarpkgconfigpoormanprettyunitsprogressproxyR6RColorBrewerRcpprlangs2scalessfstringitibbletransformrtweenrunitsutf8vctrsviridisLitewithrwk

Visualising the output of Monte Carlo methods with ggsmc

Rendered fromVisualising.Rmdusingknitr::rmarkdownon Oct 29 2024.

Last update: 2024-07-23
Started: 2024-07-21

Readme and manuals

Help Manual

Help pageTopics
An animated density of a single variable across targets.animate_density
An animated histogram of a single variable across targets.animate_histogram
Plot animated line graph showing parameter value vs dimension (revealed in the animation) from algorithm output.animate_reveal_time_series
A histogram of a single variable from a single target.animate_scatter
Plot animated line graph showing parameter value vs dimension across targets from algorithm output.animate_time_series
Data generated from a constant velocity (or continuous white noise acceleration, CWNA) model for 20 time steps.cwna_data
10000 simulations from a stochastic Lotka-Volterra model, assigned weights according to a Gaussian approximate Bayesian computation kernel with tolerance equal to 50.lv_output
Convert IS, SMC or EnK output stored as a matrix to tidy format.matrix2tidy
The output of an SMC sampler where the initial distribution is a Gaussian and the final target is a mixture of Gaussians. 25 particles were used, with an adaptive method to determine the sequence of targets, and a Metropolis-Hastings move to move the particles at each step.mixture_25_particles
A density of a single variable.plot_density
Plot an SMC or EnK genealogy from algorithm output.plot_genealogy
A histogram of a single variable.plot_histogram
A histogram of a single variable from a single targetplot_scatter
Plot line graph showing parameter value vs dimension from algorithm output.plot_time_series
The output of a bootstrap particle filter on the 'cwna_data'. The output consists of 100 particles over 20 time steps.sir_cwna_model