scc_cause_sets {epicmodel}R Documentation

Extracting component causes from SCC model

Description

Extracting component causes by sufficient cause from an epicmodel_scc object.

Usage

scc_cause_sets(
  scc,
  output = c("id", "desc", "desc_no_start", "all"),
  depends = TRUE,
  unknown = FALSE
)

Arguments

scc

An object of class epicmodel_scc.

output

A single element of type character, which determines the type of output. Options are "id", "desc", "desc_no_start", and "all". See returns-part below for description.

depends

TRUE (default) or FALSE. If FALSE, only includes sufficient causes with sc_status "always".

unknown

TRUE or FALSE (default). If TRUE, unknown causes are added to the SCC model: every sufficient cause gets an additional individual unknown component cause representing additional unknown components; an unknown sufficient cause is added to the model consisting of a single unknown component cause and representing all unknown sufficient causes.

Value

A named list but its content depends on parameter "output". The names correspond to the component cause set IDs, i.e., ⁠cc[[:digit:]]+⁠.

Examples

# Create some SCC model
steplist_checked <- check_steplist(steplist_rain)
scc_model <- create_scc(steplist_checked)

# Get sets of component causes that form the sufficient causes
scc_cause_sets(scc_model, output = "all")

[Package epicmodel version 0.2.0 Index]