bm: Data list benchmark

Description Usage Arguments Details Value See Also Examples

Description

Extract the 'benchmark' variable from a data list.

Usage

1
bm(x)

Arguments

x

A data list.

Details

When data.list, as.data.list, dlcast, or read.multitable is used to create a new data list object, one of the variables in this object is designated to be the 'benchmark' variable. The first variable passed to data.list that is replicated along every dimension is designated the benchmark. The "bm" attribute in a data.list object gives the subscript of the benchmark variable. Thus, the bm function is a single line: x[[attr(x, "bm")]].

Although any variable that is replicated along every dimension can serve as the benchmark, it is recommended that the benchmark be a response variable if such a variable exists. Therefore, such a response variable should be the first variable passed to data.list.

The purpose of the benchmark is to provide a frame of reference for other less-replicated variables in a data list and is a prototype of the replication in a data list as a whole. In this way, one may access the names of the dimensions of the data list simply by accessing the names of the dimensions of the benchmark. Indeed, this is how dimnames.data.list works.

Value

The benchmark variable.

See Also

data.list; as.data.list

Examples

1
2

stevencarlislewalker/multitable documentation built on May 30, 2019, 4:44 p.m.