Generating prediction using a back-propagation neural network model on R returns same values for all observation
问题 I'm trying to generate prediction using a trained backpropagation neural network using the neuralnet package on a new data set. I used the 'compute' function but end up with the same value for all observations. What did I do wrong? # the data Var1 <- runif(50, 0, 100) sqrt.data <- data.frame(Var1, Sqrt=sqrt(Var1)) # training the model backnet = neuralnet(Sqrt~Var1, sqrt.data, hidden=2, err.fct="sse", linear.output=FALSE, algorithm="backprop", learningrate=0.01) print (backnet) Call: neuralnet