Learn R Programming

emdbook (version 1.3.13)

perturb.params: Create a list of perturbed parameters

Description

Takes a baseline set of parameters and perturbs it to create a variety of starting points for maximum likelihood estimation or MCMC

Usage

perturb.params(base, alt, which, mult = FALSE, use.base = TRUE)

Value

A list of named lists of parameters.

Arguments

base

a named list (or vector) of parameters

alt

a list of lists (or vectors) of alternative parameter values or multipliers

which

which parameters to perturb (currently unused)

mult

(logical) multiply baseline values rather than replacing them?

use.base

(logical) include baseline parameters in the list?

Author

Ben Bolker

Details

Takes the baseline parameter list and substitutes alternative values.

Examples

Run this code
perturb.params(list(x=1,y=2,z=3),alt=list(x=c(2,4),z=5))

Run the code above in your browser using DataLab