[S] NNET question

Thomas J. Downing (t_downing@yahoo.com)
Wed, 7 Oct 1998 12:29:09 -0700 (PDT)



I am utilizing V & R's nnet library in an attempt to better
understand neural networks. Although I can make predictions using
predict.nnet, I do not think I quite understand how predictions are
derived from the weights given in the output. For example, I have
fit the following 2-2-1 network :

> z.nnet <- nnet(z ~ x + y,data = ds,size = 2, decay = .007)
# weights: 9
initial value 164.278441
iter 10 value 99.745092
.
iter 100 value 97.279519
final value 97.279519
stopped after 100 iterations

> summary(z.nnet)
a 2-2-1 network with 9 weights
options were - decay=0.007
b->h1 i1->h1 i2->h1
2.16 0.36 3.81
b->h2 i1->h2 i2->h2
5.89 4.91 -2.00
b->o h1->o h2->o
3.46 -5.85 -8.83

Given this information, I (naively?) assumed that the forecasting
equation would be given by:

Z(i) = 3.46 - 5.85 * h1 - 8.83 * h2

where:
h1 = 2.16 + .36 * x + 3.81 * y
h2 = 5.89 + 4.91 * x - 2 * y

However, when I use these formulas for prediction, I get very different
(and obviously very wrong) predictions than those given by
predict.nnet.
What am I doing wrong? Thank you in advance for any help with this
problem!

==
-

Thomas J. Downing
Research Assistant
Quantitative Research
Value Line, Inc.

_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com

-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news