Thinking Stuff's ATM

Automated Trading Machine (ATM) makes it simple to remove fear and greed from your trading. Automated trading is no longer just for the rich or nerdy. Our revolutionary software runs on your computer, using your trading rules, but none of your emotions. There's just one requirement - you know how to use a mouse.  Learn more...

Thinking Stuff's ATE

Automated Trading Execution (ATE) is where we run your trading systems for you on our servers. Your system can be exported from ATM, or written in plain English and we'll make it for you. We'll even backtest and suggest improvements if you want us to. This service essentially automates your automated trading.  Learn more...

Thinking Stuff's Groups

Join a group of like-minded individuals, and help each other to trading success. Once you join a group, you will have access to that group's trading systems, ideas, and feedback. And please contribute your own knowledge as much as possible. Or contact us to start your own group.  Learn more...

Random Number Between 0 And Max 255

There is a custom indicator called "Special / Miscellaneous". And in that custom indicator family is an indicator called "Random number between 0 and max 255".

What that results in is a line filled with random numbers between 0 (zero) and the upper limit you specify. The upper limit can be anything from 1 to 255 (actually you can enter a bigger number, but even if you do so 255 is used).

How is this useful?

Sometimes people like to test the results of their trading system against the results obtained by chance. Along the lines of "are all my fancy rules giving any better result than tossing a coin?"

So after creating your fancy trading system, copy it, delete all entry rules, and replace with one involving this random number. Test the results.

Only whole numbers are used, no decimal points. So a random number between 0 and 1 means that the result will either be 0 or it will be 1. There are only 2 possible results. It's 50-50 as to which will come up, chosen randomly by the computer. So this is just like tossing a coin. Create an entry rule that says only enter when the random number equals 1. And that would give a trading signal, on average, every second bar.

Similarly, a random number between 0 and 5 would be like rolling a dice (as there are 6 possible results - 0, 1, 2, 3, 4, 5).

But normally trading signals aren't given every 2 or 6 bars. If you have tested your original system, you can work out roughly how often it gives trading signals. And then set the upper limit on this random generator to something similar. If you want to do this kind of comparison, you have to be comparing apples with apples.

Just remember that 0 (zero) is always going to be one of the possible results, so if you want a signal approximately every 20 bars then enter an upper limit of 19.
 

Groups: