get_parameter_def_distribution: Get the definition of given parameter distribution defined in...

Description Usage Arguments Details Value Examples

View source: R/2a_parameter_estimation_functions.R

Description

Get the definition of given parameter distribution defined in a file

Usage

1
2
3
4
5
6
7
get_parameter_def_distribution(
  parameter,
  paramfile,
  colnames_paramdistr,
  strategycol = NA,
  strategyname = NA
)

Arguments

parameter

parameter of interest

paramfile

data file to be provided

colnames_paramdistr

list of column names for the parameters that define the distribution

strategycol

treatment strategy column name

strategyname

treatment strategy name in the column strategycol

Details

This function reads the parameter distribution from a file and return the parameter obtained This assumes that the file contains parameter, distribution colnames for parameter values for the distribution are passed on to the function assumes the name of each parameter and value are given in the consecutive columns. Once the expression is created using the parameters given in the file, it gets checked for correctness of specifying the distribution in R context using the function check_estimate_substitute_proper_params and then evaluated.

Value

the definition of parameter from the given distribution

Examples

1
2
3
4
paramfile <- system.file("extdata", "table_param.csv",
package = "packDAMipd")
a <- get_parameter_def_distribution("rr", paramfile, c("Param1_name",
"Param1_value"))

packDAMipd documentation built on March 3, 2021, 5:07 p.m.