spl_variable: Variable associated with a split

spl_variableR Documentation

Variable associated with a split

Description

This function is intended for use when writing custom splitting logic. In cases where the split is associated with a single variable, the name of that variable will be returned. At time of writing this includes splits generated via the split_rows_by(), split_cols_by(), split_rows_by_cuts(), split_cols_by_cuts(), split_rows_by_cutfun(), and split_cols_by_cutfun() layout directives.

Usage

spl_variable(spl)

## S4 method for signature 'VarLevelSplit'
spl_variable(spl)

## S4 method for signature 'VarDynCutSplit'
spl_variable(spl)

## S4 method for signature 'VarStaticCutSplit'
spl_variable(spl)

## S4 method for signature 'Split'
spl_variable(spl)

Arguments

spl

(VarLevelSplit)
the split object.

Value

For splits with a single variable associated with them, returns the split. Otherwise, an error is raised.

See Also

make_split_fun


Roche/rtables documentation built on April 30, 2024, 11:18 p.m.