createXblocks: Create list of paired data blocks

Description Usage Arguments Details Value See Also Examples

View source: R/MultiLambdaCVfun.R

Description

Create list of paired data blocks

Usage

1
createXblocks(datablocks, which2pair = NULL)

Arguments

datablocks

List of data frames or matrices representing b=1,...,B data blocks of dimensions n x p_b.

which2pair

Integer vector of size 2 (or NULL)

Details

Only use this function when you wish to pair two data blocks. If which2pair = NULL the output matches the input. If not, the function adds a paired data block, pairing the two data blocks corresponding to the elements of which2pair.

Value

List. Same length as datablocks when which2pair = NULL, or augmented with one paired data block.

See Also

createXXblocks. A full demo and data are available from:
https://drive.google.com/open?id=1NUfeOtN8-KZ8A2HZzveG506nBwgW64e4

Examples

1
2
3
n <- 43
p <- 100
fakeXbl <- createXblocks(list(X1 = matrix(rnorm(n*p),nrow=n),X2 = matrix(rnorm(n*p),nrow=n)))

multiridge documentation built on June 15, 2021, 9:08 a.m.