Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

summary_simulate

Summarize a matrix of simulations by their mean (median), sd (mad), and quantiles


Description

Utility function to summarize the output from ‘simulate’ functions in this package

Usage

summary_simulate(object, probs = c(0.025, 0.975), robust = FALSE, ...)

Arguments

object

nobs x nsim matrix where nobs are the number of observations in the dataset and nsim are the number of simulations

probs

the percentiles to be computed by the quantile function

robust

If FALSE (the default) the mean is used as the measure of central tendency and the standard deviation as the measure of variability. If TRUE, the median and the median absolute deviation (MAD) are applied instead.

...

additional arguments to be passed. (none used at the moment)

Examples

data(barley, package = "nlraa")
fit <- nls(yield ~ SSlinp(NF, a, b, xs), data = barley)
sim <- simulate_nls(fit, nsim = 100)
sims <- summary_simulate(sim)

nlraa

Nonlinear Regression for Agricultural Applications

v0.89
GPL-3
Authors
Fernando Miguez [aut, cre] (<https://orcid.org/0000-0002-4627-8329>), José Pinheiro [ctb, cph] (author of nlme::nlsList, nlme::predict.gnls, nlme::predict.nlme), Douglas Bates [ctb, cph] (author of nlme::nlsList, nlme::predict.gnls, nlme::predict.nlme), R-core [ctb, cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.