params: Create a data.frame of class "gadget_params"

Description Usage Value Examples

Description

These functions create and update a data.frame of class gadget_params. This is the parameter file for switches used in a Gadget model

Usage

1
2
3
make_gadget_params()

init_params(df, switch, value, lower, upper, optimize = TRUE)

Value

A data.frame of class gadget_params. make_gadget_params returns an empty data.frame, and init_params updates the parameter found by switch.

Examples

1
2
3
4
5
6
7
8
9
params <- make_gadget_params()
params <- init_params(params, "linf", 125, 115, 135)
params <- init_params(params, "k", 0.25, 0.1, 0.3, optimize = FALSE)

# setup for efficient use with dplyr
params <-
  make_gadget_params() %>%
  init_params("linf", 125, 115, 135) %>%
  init_params("k", 0.25, 0.1, 0.3, optimize = FALSE)

inspktrgadget/gadgetSim documentation built on May 10, 2019, 9:51 a.m.