joinet.html 11.3 KB
 Armin Rauschenberger committed Dec 19, 2018 1 2   Armin Rauschenberger committed Jul 31, 2019 3   Armin Rauschenberger committed Dec 19, 2018 4 5 6 7 8   Armin Rauschenberger committed Jul 31, 2019 9 Multivariate Elastic Net Regression — joinet • joinet  Armin Rauschenberger committed Dec 19, 2018 10 11   Armin Rauschenberger committed Jul 31, 2019 12   Armin Rauschenberger committed Dec 19, 2018 13   Armin Rauschenberger committed Jul 31, 2019 14   Armin Rauschenberger committed Dec 19, 2018 15   Armin Rauschenberger committed Jul 31, 2019 16   Armin Rauschenberger committed Dec 19, 2018 17 18   Armin Rauschenberger committed Jul 31, 2019 19   Armin Rauschenberger committed Dec 19, 2018 20 21   Armin Rauschenberger committed Jul 31, 2019 22   Armin Rauschenberger committed Dec 19, 2018 23 24 25 26 27 28 29 30 31 32   Armin Rauschenberger committed Jul 31, 2019 33   Armin Rauschenberger committed Dec 19, 2018 34   Armin Rauschenberger committed Jun 07, 2019 35   Armin Rauschenberger committed Dec 19, 2018 36 37 38 39 40   Armin Rauschenberger committed Jul 31, 2019 41 42   Armin Rauschenberger committed Dec 19, 2018 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 
 Armin Rauschenberger committed Jun 07, 2019 118 

Implements multivariate elastic net regression.

 Armin Rauschenberger committed Dec 19, 2018 119 120 121 
 Armin Rauschenberger committed Jul 31, 2019 122 
joinet(Y, X, family = "gaussian", nfolds = 10, foldid = NULL, 
Armin Rauschenberger committed Aug 02, 2019  123                                                                                                                type.measure = "deviance", alpha.base = 1, alpha.meta = 0, ...)
 Armin Rauschenberger committed Dec 19, 2018 124 125 126 127 128 

Arguments

Y

outputs: numeric matrix with $$n$$ rows (samples) and $$q$$ columns (variables), with positive correlation (see details)

X

inputs:  Armin Rauschenberger committed Dec 19, 2018 138 139 numeric matrix with $$n$$ rows (samples) and $$p$$ columns (variables)

family

distribution: vector of length $$1$$ or $$q$$ with entries "gaussian", "binomial" or "poisson"

nfolds

number of folds

foldid

fold identifiers:  Armin Rauschenberger committed Jun 07, 2019 154 vector of length $$n$$ with entries between $$1$$ and nfolds;  Armin Rauschenberger committed Jan 08, 2019 155 156 or NULL (balance)

type.measure

loss function: vector of length $$1$$ or $$q$$ with entries "deviance", "class", "mse" or "mae"  Armin Rauschenberger committed Jul 31, 2019 162 (see cv.glmnet)

alpha.base

elastic net mixing parameter for base learners: numeric between $$0$$ (ridge) and $$1$$ (lasso)

alpha.meta

elastic net mixing parameter for meta learner:  Armin Rauschenberger committed Jun 11, 2019 172 numeric between $$0$$ (ridge) and $$1$$ (lasso)

...

further arguments passed to glmnet

 Armin Rauschenberger committed Jun 07, 2019 129 130 131 132 133   Armin Rauschenberger committed Dec 19, 2018 134 135 136   Armin Rauschenberger committed Jun 07, 2019 137   Armin Rauschenberger committed Jan 17, 2019 140 141   Armin Rauschenberger committed Jun 07, 2019 142 143 144 145   Armin Rauschenberger committed Dec 19, 2018 146   Armin Rauschenberger committed Dec 20, 2018 147 148   Armin Rauschenberger committed Jun 07, 2019 149   Armin Rauschenberger committed Dec 20, 2018 150   Armin Rauschenberger committed Jan 08, 2019 151 152 153   Armin Rauschenberger committed Dec 21, 2018 157 158   Armin Rauschenberger committed Jun 07, 2019 159 160 161   Armin Rauschenberger committed Jun 07, 2019 163 164 165 166 167 168 169 170 171   Armin Rauschenberger committed Jun 07, 2019 173 174 175   Armin Rauschenberger committed Jul 31, 2019 176   Armin Rauschenberger committed Dec 21, 2018 177   Armin Rauschenberger committed Dec 19, 2018 178 179   Armin Rauschenberger committed Aug 02, 2019 180 181 182 183 184 185 186 187 188 189 

Value

This function returns an object of class joinet. Available methods include predict, coef, and weights. The slots base and meta each contain $$q$$ cv.glmnet-like objects.

 Armin Rauschenberger committed Feb 20, 2019 190 191 

Details

 Armin Rauschenberger committed Aug 02, 2019 192 193 

correlation: The $$q$$ outcomes should be positively correlated.  Armin Rauschenberger committed Jun 07, 2019 194 Avoid negative correlations by changing the sign of the variable.

 Armin Rauschenberger committed Aug 02, 2019 195 

elastic net:  Armin Rauschenberger committed Jun 11, 2019 196 197 alpha.base controls input-output effects, alpha.meta controls output-output effects;  Armin Rauschenberger committed Aug 02, 2019 198 199 lasso renders sparse models (alpha$$=1$$), ridge renders dense models (alpha$$=0$$)

 Armin Rauschenberger committed Jun 07, 2019 200 201 202 

References

 Armin Rauschenberger committed Aug 02, 2019 203 

Armin Rauschenberger, Enrico Glaab (2019)  Armin Rauschenberger committed Aug 08, 2019 204 205 "joinet: predicting correlated outcomes jointly to improve clinical prognosis"  Armin Rauschenberger committed Aug 02, 2019 206 Manuscript in preparation.

 Armin Rauschenberger committed Feb 20, 2019 207   Armin Rauschenberger committed Aug 07, 2019 208 209 

 Armin Rauschenberger committed Aug 08, 2019 210 
 Armin Rauschenberger committed Aug 07, 2019 211   Armin Rauschenberger committed Dec 19, 2018 212 213 
 Armin Rauschenberger committed Aug 07, 2019 214 
n <- 50; p <- 100; q <- 3  Armin Rauschenberger committed Jul 31, 2019 215 X <- matrix(rnorm(n*p),nrow=n,ncol=p)  Armin Rauschenberger committed Aug 06, 2019 216 Y <- replicate(n=q,expr=rnorm(n=n,mean=rowSums(X[,1:5])))  Armin Rauschenberger committed Aug 08, 2019 217 218 219 220 object <- joinet(Y=Y,X=X)
 Armin Rauschenberger committed Dec 19, 2018 221 222 223 224 225