is.blocks: Check variable blocking

Description Usage Arguments Value Examples

View source: R/sinhelpfunctions.R

Description

This function checks whether a list of vectors defines a valid decomposition of the set of variables into blocks.

Usage

1
is.blocks(blocks, p)

Arguments

blocks

a list of integer vectors representing a family of subsets of the variable set.

p

the number of variables.

Value

The function returns TRUE if the block structure is such that each variable is represented in exactly one of the blocks. Otherwise, FALSE is returned.

Examples

1
2
3
4
5
6
7
p <- 6
blocks <- list(1:3,6,5:4)
is.blocks(blocks, p)
blocks <- list(1:3,7,5:4)
is.blocks(blocks, p)
blocks <- list(1:2,6,5:4)
is.blocks(blocks, p)

SIN documentation built on May 2, 2019, 8:23 a.m.

Related to is.blocks in SIN...