Computing the I2C2 of the permuted data.

I2C2.rsample(s = 1, y, id, visit, ...)

resample_id(s = 1, y, id, visit)

Arguments

s

Random seed, Default = 1

y

An n by p data matrix containing n vectorized image data with p voxels. Each row contains one observed image data at a particular visit for one subject. Each column contains image values for all subjects and visits at a particular voxel.

The rows are organized by subjects and then visits, EX) (Y11, Y12, Y21, Y22, ... , YI1 , YI2)

id

Vector of IDs, EX) c(1, 1, 2, 2, 3, 3, 4, 4, ... , I, I)

visit

Vector of visits, EX) (1, 2, 1, 2, 1, 2, ... , 1, 2)

...

arguments to pass to I2C2

Value

Set of lambda values

Examples

id = c(1:10, 10:1)
visit = rep(1:2, each = 10)
visit = as.character(visit)
n = length(id)
p = 100
y = matrix(rnorm(n * p), nrow = n, ncol = p)
L = resample_id(s = 10, y = y, id = id, visit = visit)