edwardBe
01-22-2009, 11:04 PM
If someone is interested in writing an EA, Martin Alexander's manual trading system for the M30 chart would be an interesting one to run.
In my own little pseudocode the logic is every few seconds within any given bar the EA would need to run this check:
if ((current_bar_high > previous_bar_high) and (current_bar_price < current_bar_open)) {
open_sell_trade;
set_stop_loss = (current_bar_high + 1);
}
else if((current_bar_low < previous_bar_low) and (current_bar_price > current_bar_open)) {
open_buy_trade;
set_stop_loss = (current_bar_low - 1);
}
else {
do nothing;
}
Once the trade is entered, the checks should stop, of course.
Then the trade exits at the close of the current bar and the logic starts over for the next bar. He doesn't say anything about setting take profit levels or letting profitable trades run. It is a bar by bar strategy with any bar being a setup bar, but only those bars that fit the logic above being traded.
I've used the strategy manually and it works fairly well, but it requires a lot of monitoring and it is very tempting to second guess the strategy by looking at what previous bars have done. Automating it would make it a little less tempting as you could leave that window if not the room, only to return to find your millions waiting of course! :D
In my own little pseudocode the logic is every few seconds within any given bar the EA would need to run this check:
if ((current_bar_high > previous_bar_high) and (current_bar_price < current_bar_open)) {
open_sell_trade;
set_stop_loss = (current_bar_high + 1);
}
else if((current_bar_low < previous_bar_low) and (current_bar_price > current_bar_open)) {
open_buy_trade;
set_stop_loss = (current_bar_low - 1);
}
else {
do nothing;
}
Once the trade is entered, the checks should stop, of course.
Then the trade exits at the close of the current bar and the logic starts over for the next bar. He doesn't say anything about setting take profit levels or letting profitable trades run. It is a bar by bar strategy with any bar being a setup bar, but only those bars that fit the logic above being traded.
I've used the strategy manually and it works fairly well, but it requires a lot of monitoring and it is very tempting to second guess the strategy by looking at what previous bars have done. Automating it would make it a little less tempting as you could leave that window if not the room, only to return to find your millions waiting of course! :D