RBFval | R Documentation |
RBFval
classifies instances in a test set using a radial basis function classifier. Function
calcm
is called for computing output belief functions. It is recommended to set
calc.belief=FALSE
when the number of classes is very large, to avoid memory problems.
RBFval(x, param, y = NULL, calc.belief = TRUE)
x |
Matrix of size n x d, containing the values of the d attributes for the test data. |
param |
Neural network parameters, as provided by |
y |
Optional vector of class labels for the test data. May be a factor, or a vector of integers from 1 to M (number of classes). |
calc.belief |
If TRUE (default), output belief functions are calculated. |
If class labels for the test set are provided, the test error rate is also returned.
A list with four elements:
Predicted class labels for the test data.
Test error rate (if the class label of test data has been provided).
Output probabilities.
If calc.belief=TRUE
, output belief function, provided as a list
output by function calcm
.
Thierry Denoeux.
T. Denoeux. Logistic Regression, Neural Networks and Dempster-Shafer Theory: a New Perspective. Knowledge-Based Systems, Vol. 176, Pages 54–67, 2019.
Ling Huang, Su Ruan, Pierre Decazes and Thierry Denoeux. Lymphoma segmentation from 3D PET-CT images using a deep evidential network. International Journal of Approximate Reasoning, Vol. 149, Pages 39-60, 2022.
RBFinit
, RBFfit
, calcm
## Glass dataset
data(glass)
xapp<-glass$x[1:89,]
yapp<-glass$y[1:89]
xtst<-glass$x[90:185,]
ytst<-glass$y[90:185]
## Initialization
param0<-RBFinit(xapp,yapp,nproto=7)
## Training
fit<-RBFfit(xapp,yapp,param0)
## Test
val<-RBFval(xtst,fit$param,ytst)
## Confusion matrix
table(ytst,val$ypred)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.