Skip to contents

Data fusion

Usage

fuse.data(x, y = NULL, foldid = NULL)

Arguments

x

list of q matrices, with n_1,...,n_q rows and with p columns

y

list of q vectors, of length n_1,...,n_q, or NULL (default)

foldid

list of q vectors, of length n_1,...n_q, or NULL (default)

Examples

data <- sim.data.transfer()
sapply(X=data$y_train,FUN=length)
#> [1]  50 100 200
sapply(X=data$X_train,FUN=dim)
#>      [,1] [,2] [,3]
#> [1,]   50  100  200
#> [2,]  200  200  200
fuse <- fuse.data(x=data$X_train,y=data$y_train)
length(fuse$y)
#> [1] 350
dim(fuse$x)
#> [1] 350 200
table(fuse$index)
#> 
#>   1   2   3 
#>  50 100 200