Description Usage Arguments Value Examples
Supervised Integrated Factor Analysis
1 2 3 4 5 6 7 8 9 10 11 |
X |
n*q matrix, centered covariate data |
Y |
1*K cell array, each cell is a n*pi centered primary data, should roughly contribute equally to joint struct |
r0 |
scalar, prespecified rank of common structure |
r |
1*K vector, prespecified rank of specific structures |
relation |
'linear' (default), use linear function to model the relation between U and covariates 'univ_kernel', use kernel methods for single covariates |
sparsity |
1 (default), when est B0 or B, use LASSO with BIC to select the best tuning, suitable for high |
max_niter |
default 1000, max number of iteration |
convg_thres |
default 0.01, overall convergence threshold |
type |
"A" or "Anp" or "B" or "Bnp", condition to use |
list with components
B0: |
q*r0 matrix, coefficient for joint structure (may be sparse) |
B: |
1*K cell array, each is a q*ri coefficient matrix (may be sparse) |
V_joint: |
sum(p)*r0 matrix, stacked joint loadings, with orthonormal columns. |
V_ind: |
1*K array, each is a pi*ri loading matrix, with orthonormal columns |
se2: |
1*K vector, noise variance for each phenotypic data set |
Sf0: |
r0*r0 matrix, diagonal covariance matrix |
Sf: |
1*K array, each is a ri*ri diagonal covariance matrix |
EU: |
n*(r0+sum(ri)) matrix, conditional expectation of joint and individual scores |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | ## Not run:
r0 <- 2
r <- c(3,3)
V <- matrix(stats::rnorm(10*2),10,2)
Fmatrix <- matrix(MASS::mvrnorm(n=1*500,rep(0,2),matrix(c(9,0,0,4),2,2)),500,2)
E <- matrix(stats::rnorm(500*10,0,3),500,10)
X <- tcrossprod(Fmatrix,V)+E
X <-scale(X,center=TRUE,scale=FALSE)
Y1 <- matrix(stats::rnorm(500*200,0,1),500,200)
Y2 <- matrix(stats::rnorm(500*200,0,1),500,200)
Y <- list(Y1,Y2)
SIFA(X,Y,r0,r,max_niter=200)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.