Description Usage Arguments Value Examples
Calculate the averaged prediction error across tasks. For classification problem, the miss-classification rate is returned, and for regression problem, the mean square error(MSE) is returned.
1 |
m |
A MTL model |
newX |
The feature matrices of new individuals |
newY |
The responses of new individuals |
The averaged prediction error
1 2 3 4 5 6 7 8 9 | #create example data
data<-Create_simulated_data(Regularization="L21", type="Regression")
#train a model
model<-MTL(data$X, data$Y, type="Regression", Regularization="L21",
Lam1=0.1, Lam2=0, opts=list(init=0, tol=10^-6, maxIter=1500))
#calculate the training error
calcError(model, newX=data$X, newY=data$Y)
#calculate the test error
calcError(model, newX=data$tX, newY=data$tY)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.