parms: Extract model parameters from mkinfit models

View source: R/parms.mkinfit.R

parmsR Documentation

Extract model parameters from mkinfit models

Description

This function always returns degradation model parameters as well as error model parameters, in order to avoid working with a fitted model without considering the error structure that was assumed for the fit.

Usage

parms(object, ...)

## S3 method for class 'mkinfit'
parms(object, transformed = FALSE, ...)

## S3 method for class 'mmkin'
parms(object, transformed = FALSE, ...)

Arguments

object

A fitted model object. Methods are implemented for mkinfit() objects and for mmkin() objects.

...

Not used

transformed

Should the parameters be returned as used internally during the optimisation?

Value

For mkinfit objects, a numeric vector of fitted model parameters. For mmkin row objects, a matrix with the parameters with a row for each dataset. If the mmkin object has more than one row, a list of such matrices is returned.

Examples

# mkinfit objects
fit <- mkinfit("SFO", FOCUS_2006_C, quiet = TRUE)
parms(fit)
parms(fit, transformed = TRUE)

# mmkin objects
ds <- lapply(experimental_data_for_UBA_2019[6:10],
 function(x) subset(x$data[c("name", "time", "value")]))
names(ds) <- paste("Dataset", 6:10)
## Not run: 
fits <- mmkin(c("SFO", "FOMC", "DFOP"), ds, quiet = TRUE, cores = 1)
parms(fits["SFO", ])
parms(fits[, 2])
parms(fits)
parms(fits, transformed = TRUE)

## End(Not run)

mkin documentation built on July 12, 2022, 5:07 p.m.

Related to parms in mkin...