Artificial Input Test

29Jan10

As I have seriously concerned that maybe the NN implementation is buggy. One way to resolve this concern is to test with
an artificial data and insert artificial patterns.

I decided that a periodic 5 days SPX increase on increasing volume can be repeated as a pattern.
It looks like this:

My first version was deterministic. Later I modified it to be a little random (but not too much)
In Matlab code:
cycleOffset = 0;
for i = 1:1:nDaysArtif
spArtif(i,1) = 1110 + cycleOffset * 10 + rand(1,1)*10;
spArtif(i,2) = 1e+10 + cycleOffset * 1 * 1e+9 + rand(1,1)* 1e+9;
if (cycleOffset == 4)
cycleOffset = 0;
else
cycleOffset = cycleOffset + 1;
end
end

The NN learned the patter flawlessly.

WinLoseRatio:100%.
AvgDailyGain: 1.4068%.
AvgDailyGain*260: 365.7767%.
Accumulated plotted gain in period:3629.4698%
the chart:

So, the NN works. It predicted the pattern in the last 260 days with 100% accuracy. So, it can recognize patters.
Why cannot it recognize the patterns in the SPX data?
Great questions of life.
Maybe the real life input lacks any pattern?

Advertisements


No Responses Yet to “Artificial Input Test”

  1. Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: