grnn.optmiz_auc {yager} | R Documentation |
Optimize the optimal value of GRNN smoothing parameter based on AUC
Description
The function grnn.optmiz_auc
optimize the optimal value of GRNN smoothing parameter by cross-validation.
It is applicable to the classification.
Usage
grnn.optmiz_auc(net, lower = 0, upper, nfolds = 4, seed = 1, method = 1)
Arguments
net |
A GRNN object generated by grnn.fit() |
lower |
A scalar for the lower bound of the smoothing parameter |
upper |
A scalar for the upper bound of the smoothing parameter |
nfolds |
A scalar for the number of n-fold, 4 by default |
seed |
The seed value for the n-fold cross-validation, 1 by default |
method |
A scalar referring to the optimization method, 1 for Golden section searc and 2 for Brent’s method |
Value
The best outcome
See Also
Examples
data(iris, package = "datasets")
Y <- ifelse(iris[, 5] == "setosa", 1, 0)
X <- scale(iris[, 1:4])
gnet <- grnn.fit(x = X, y = Y)
## Not run:
grnn.optmiz_auc(net = gnet, lower = 3, upper = 7, nfolds = 2)
## End(Not run)
[Package yager version 0.1.1 Index]