Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Problem with 1-step ahead prediction in neural network
Replies: 9   Last Post: Oct 23, 2013 6:23 AM

 Messages: [ Previous | Next ]
 Greg Heath Posts: 6,387 Registered: 12/7/04
Re: Problem with 1-step ahead prediction in neural network
Posted: Oct 23, 2013 6:23 AM

"phuong" wrote in message <l47pqt\$nva\$1@newscl01ah.mathworks.com>...
> "Greg Heath" <heath@alumni.brown.edu> wrote in message
> > > If my understand is right, I really wonder about the following:
> > > 1. with only weight set, I think we have only mse for network in train.

> > ?
> > I do not understand the statement.

>
> > Even it not change in predict on a fix range of time by 1-step( apply weight for new input and calculate mse again).
> >
> > I don't understand.

>
> Assume I follow by your way, I found the best Delay and Hidden for network. With delay and hidden,e.g delay = 10, hidden =4, we will found only weight set for network(althought we have many nets but just to change the order of weight). If it right, it lead to network just give only result for 1 pattern input. And same thing, we just only have 1 mse result for network to apply for some pattern input set( i just apply and calculate again mse not retrain). But when i run code and test on fix new pattern input set. For each run, I get a new mse to apply. I try to set a fix intialize weight, I see mse not change. So what the reason make msse change if we just have only weight set for network?
>
> Please do not be angry if I say something wrong. I'm just trying to understand right.
> I want to create a network and test it on the new input sets, then measure error of network, check trend(up or down) of predict value to corresponding with real value.
> Thank you so much
> Phuong

I still do not understand. We seem to be going around in circles because of a communication problem.

Please demonstrate w.r.t. your solution to one of the first 5 of these MATLAB NARNET examples

% help nndatasets

% Single Time-Series Prediction, Forecasting, Dynamic modelling,
% Nonlinear autoregression, System identification, and Filtering
%
% Single time-series prediction involves predicting the next value
% of a time-series given its past values.
%
% simplenar_dataset - Simple single series prediction dataset.
% oil_dataset - Monthly oil price dataset
% ice_dataset - Global ice volume dataset.
% river_dataset - River flow dataset.
% chickenpox_dataset - Monthly chickenpox instances dataset.
%
% solar_dataset - Sunspot activity dataset.
% laser_dataset - Chaotic far-infrared laser dataset.
%
% Use the help and doc commands for more details. For example
%
% help oil_dataset
% doc oil_dataset

close all, clear all, clc, plt=0

T = simplenar_dataset; % Simple single series prediction dataset.
t = cell2mat(T);
whos
% Name Size Bytes Class
% T 1x100 6800 cell
% t 1x100 800 double
plt = plt+1, figure(plt) % figure 1
plot( t, 'LineWidth', 2)
title( ' SIMPLENAR DATASET ' )
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
T = oil_dataset; % Monthly oil price dataset.
t = cell2mat(T);
whos
% Name Size Bytes Class
%
% T 1x180 13680 cell
% t 2x180 2880 double
plt = plt+1, figure(plt) % figure 5
subplot(211)
plot( t(1,:), 'LineWidth', 2)
title( ' OIL DATASET ' )
subplot(212)
plot( t(2,:), 'LineWidth', 2)
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
T = ice_dataset; % Global ice volume dataset
t = cell2mat(T);
whos
% Name Size Bytes Class
%
% T 1x219 14892 cell
% t 1x219 1752 double
plt = plt+1, figure(plt) % figure 3
plot( t, 'LineWidth', 2)
title( ' ICE DATASET ' )
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
T = river_dataset ; % River flow dataset.
t = cell2mat(T);
whos
plt = plt+1, figure(plt) % figure 6
plot( t, 'LineWidth', 2)
title( ' RIVER DATASET ' )
% Name Size Bytes Class
%
% T 1x264 17952 cell
% t 1x264 2112 double
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
T = chickenpox_dataset; % Monthly chickenpox instances dataset.
t = cell2mat(T);
whos
% Name Size Bytes Class
%
% T 1x498 33864 cell
% t 1x498 3984 double
plt = plt+1, figure(plt) % figure 2
plot( t, 'LineWidth', 2)
title( ' CHICKENPOX DATASET ' )
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
T = solar_dataset ; % Sunspot activity dataset
t = cell2mat(T);
whos
plt = plt+1, figure(plt) % figure 7
plot( t, 'LineWidth', 2)
title( ' SOLAR DATASET ' )
% Name Size Bytes Class
%
% T 1x2899 197132 cell
% t 1x2899 23192 double
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
T = laser_dataset; % Chaotic far-infrared laser dataset.
t = cell2mat(T);
whos
% Name Size Bytes Class
%
% T 1x10093 686324 cell
% t 1x10093 80744 double
plt = plt+1, figure(plt) % figure 4
plot( t, 'LineWidth', 2)
title( ' LASER DATASET ' )

Date Subject Author
10/18/13 phuong
10/19/13 Greg Heath
10/19/13 phuong
10/19/13 Greg Heath
10/19/13 phuong
10/20/13 Greg Heath
10/21/13 phuong
10/21/13 Greg Heath
10/23/13 phuong
10/23/13 Greg Heath