if (FALSE) demo(art2_tetra)
if (FALSE) demo(art2_tetraSnnsR)
data(snnsData)
patterns <- snnsData$art2_tetra_med.pat
model <- art2(patterns, f2Units=5, learnFuncParams=c(0.99, 20, 20, 0.1, 0),
updateFuncParams=c(0.99, 20, 20, 0.1, 0))
model
testPatterns <- snnsData$art2_tetra_high.pat
predictions <- predict(model, testPatterns)
if (FALSE) library(scatterplot3d)
if (FALSE) par(mfrow=c(2,2))
if (FALSE) scatterplot3d(patterns, pch=encodeClassLabels(model$fitted.values))
if (FALSE) scatterplot3d(testPatterns, pch=encodeClassLabels(predictions))
Run the code above in your browser using DataLab