CollapseTableParser: Parsing Collapse orders from a table

Description Usage Arguments Details Value Author(s) Examples

Description

Parses data.frames of specific format to produce "Col" prefixed lists for CheckCollapse

Usage

1

Arguments

CTable

a data.frame with columns "Variable" (variable names), "Index" (column names), "Function" (function to collapse the columns), and "Probs" (probabilities of column levels in marginal distribution, comma separated. Used when function is "sample".)

env

target environment, default is .GlobalEnv

Details

Used in the Opasnet assessments/analyses to produce multiple model specific Collapse instructions. Using other distribution values than 1 requires knowledge about the amount and order of unique index values. Probs values 1 and NA are considered equal weighting.

See also: http://en.opasnet.org/

Value

No return value, "Col" prefixed variables are written straight into specified environment.

Author(s)

T. Rintala teemu.rintala.a@gmail.com

Examples

1
2
3
a <- data.frame(Variable = "test", Index = c("City"), Probs = 1)
CollapseTableParser(a)
Coltest

jtuomist/OpasnetUtils documentation built on July 10, 2020, 7:07 p.m.