calculating results (error, mse) by hand (Neural network)

Hi my friends,
I am running a neural network (NARX) with 2 lags for each input and 2 lags for targets. I got results and also I pinpointed weights and biases parameters. I made the calculation of the error by hand i.e I took weights and transfer function and applied those to data. Basically, I constructed the non-linear system and I got the error (the difference between output and target). I could not get the error provided by the NARX estimation. I checked this several times but no success. I wonder why, it seems very easy but I totally puzzled. It is a basic code, if you can have data you can do it yourself (you only need data and weights after estimation).
please help Freddy

댓글 수: 2

You will have to provide your code if you want help
it is not necessary, you can make up some numbers.

댓글을 달려면 로그인하십시오.

 채택된 답변

Freddy Rojas
Freddy Rojas 2014년 9월 21일

1 개 추천

there is something else! I figured out that this morning: the way how you arrange the data matters. Specifically, you must take into consideration this ordering for the case of 2 lags in inputs,
x1(-1) x2(-1) ... xk(-1) x1(-2) x2(-2) ... xk(-2)
I thought that ordering was as follows
x1(-1) x1(-2) ... xk(-1) xk(-2)
matlab manual does explain this poorly.
Greg is right also, you must "normalize" data between -1 and 1.
thank you!

추가 답변 (1개)

Greg Heath
Greg Heath 2014년 9월 21일

0 개 추천

MAXMIN normalization of input and output are defaults. Therefore you have to
1. Normalize inputs before multiplying with the weights
2. Unnornormalize outputs before comparing with targets.
Hope this helps.
Thank you for formally accepting my answer
Greg

카테고리

도움말 센터File Exchange에서 Deep Learning Toolbox에 대해 자세히 알아보기

질문:

2014년 9월 20일

답변:

2014년 9월 21일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by