[R] question about nnet

From: Aimin Yan <aiminy_at_iastate.edu>
Date: Sun 28 Jan 2007 - 18:30:15 GMT


I use neural network to predict a continuous variable( omega in training).

But I get all "1" instead of real value.

Do you know why?

Aimin

Thanks

The following is code

> m.nn.omega <- nnet(omega~aa_three+bas+bcu+aa_ss, aata=training,size=2)
# weights: 57
initial value 97329662.256069
final value 96367717.444383
converged
> pr.nn.train<-predict(m.nn.omega,training,type="raw")
> head(pr.nn.train)

   [,1]
1 1
2 1
3 1
4 1
5 1
6 1
> head(training)

     pr aa_three aa_one aa_ss aa_pos    aas bas   ams bms        acu 
bcu     omega       y index
1 1acx      ALA      A     C      1 127.71   0 69.99   0 
-0.2498560   0  79.91470 outward  TRUE
2 1acx      PRO      P     C      2  68.55   0 55.44   0 
-0.0949008   0  76.60380 outward  TRUE
3 1acx      ALA      A     E      3  52.72   0 47.82   0 
-0.0396550   0  52.19970 outward  TRUE
4 1acx      PHE      F     E      4  22.62   0 31.21   0  0.1270330   0 
169.52500  inward  TRUE
5 1acx      SER      S     E      5  71.32   0 52.84   0 
-0.1312380   0   7.47528 outward  TRUE
6 1acx      VAL      V     E      6  12.92   0 22.40   0  0.1728390   0 
149.09400 inward TRUE

R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Mon Jan 29 05:34:02 2007

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Sun 28 Jan 2007 - 20:30:34 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.