Learn R Programming

crunch (version 1.30.4)

makeMarginMap: Make a map of margins

Description

Useful when converting to and from user and real cube dimension indexes.

Usage

makeMarginMap(dimTypes)

Value

a vector of margins, the length of which is the length of the real cube, the values are the user cube dimensions

Arguments

dimTypes

dimension types from getDimTypes()

Examples

Run this code

if (FALSE) {
makeMarginMap(getDimTypes(cat_by_cat_cube))
# 1 2

makeMarginMap(getDimTypes(MR_by_cat_cube))
# 1 1 2

makeMarginMap(getDimTypes(cat_by_MR_cube))
# 1 2 2

makeMarginMap(getDimTypes(MR_by_MR_cube))
# 1 1 2 2
}

Run the code above in your browser using DataLab