Saturday, June 10, 2006

Forex Lab Trading System: Random Entries

These strategies are based on experiments I am conducting towards the goal of writing an automated FOREX trading robot. You can download the compiled program and its source code for this trading strategies from my website.

One strategy is based on the Stochastics RSI System.

A long entry signal occurs when the StochRSI indicator is below 25 and rising.
A short entry signal occurs when the StochRSI indicator is above 75 and falling.
If the system is long, an exit signal occurs when the StochRSI is higher than 75.
If the system is short, en exit signal occurs when the StochRSI drops below 25.
The first two parameters show how to pass simple parameters to the trading system. The system operates on candles of the lenght specified by the MINUTES parameter. The last parameters show how to do optimization with the built in brute force optimizer.


The first system is the most interesting, it is based on random entries. Each time a candle is received, the system flips a virtual coin and decides to go long or short. A fixed stop loss is set in place, and a fixed take profit is set at a multiple of the stop loss.

For example. MINUTES:5;STOP:0.0010;PROFIT:1; specifies that 5 minute candles are to be used, a fixed stop loss of 10 pips is in place, and a take profit is set at a multiple of 1 times the stop loss, resulting in a 10pips order.

The trade is allowed to run until it hits the stop loss, or the take profit level, which might occur at any time.

Money Management techniques, which indicate to cut our losses and let our profits run might tempt us to use a PROFIT:3; parameter, to have take profit orders which are three times the size of the stop loss, ie: 10 pip stop loss, 30 pip take profit.

Experiments:

Use the FOREX Lab platform to evaluate the following scenarios:

MINUTES:5;STOP:0.0010;PROFIT:3; run several times, note profitability.
MINUTES:5;STOP:0.0010;PROFIT:1; run several times, note profitability.
MINUTES:5;STOP:0.0080;PROFIT:1; run several times, note profitability.
MINUTES:5;STOP:0.0080;PROFIT:3; run several times, note profitability

Tips:

using LOG:2; after the parameters, quiets the program down and shows only the end of run summary
using LOG:3; is useful when optimizing. It shows only the end of run summaries and optimization results.
LOG:4; shows only the optimization results.
The Log.log.txt files contain all the trade information for all runs, no matter what the log level was.


To get more tick files, the source code to this system, and more, check out the 4XLab.NET Trading Systems Source Code forums

If you need assistance using the software, this Guided Tour might help

Educational Trading Resources: InvestorFLIX.COM

I recently subscribed to www.investorflix.com. This site offers a service similar to that of Netflix. For $20 a month, they send you 2 CDs or DVDs containing trading lectures. This is a very inexpensive way to learn. You can find reviews of the CDs I have received on my website.

Saturday, June 03, 2006

4XLab.NET gets a makeover

www.4xlab.net just got a small makeover. I moved some threads around and reworked the home page a little.