Description Usage Arguments Value Examples
Runs a multilayer perceptron
1 | sN.MLPpredict(nnModel, X, raw = FALSE)
|
nnModel |
A list containing the coefficients for the MLP (as produced with sN.MLPtrain()) |
X |
Matrix of predictors |
raw |
If true, returns score of each output option. If false, returns the output option with highest value. |
The predicted values obtained by the MLP
1 2 3 4 5 6 7 | data(UCI.transfusion);
X=as.matrix(sN.normalizeDF(as.data.frame(UCI.transfusion[,1:4])));
y=as.matrix(UCI.transfusion[,5]);
myMLP=sN.MLPtrain(X=X,y=y,hidden_layer_size=4,it=50,lambda=0.5,alpha=0.5);
myPrediction=sN.MLPpredict(nnModel=myMLP,X=X,raw=TRUE);
#library('verification');
#roc.area(y,myPrediction[,2]);
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.