Standard MA advisor strategy with trade time window

Strategies are published here.

Moderator: admin

Standard MA advisor strategy with trade time window

Postby Alexander.Gettinger » Wed Jan 18, 2012 4:34 am

This is a standard MA advisor strategy with the possibility specify start and end of trading session.

Download:
ma_advisor_time_window.lua
(19.1 KiB) Downloaded 986 times


ma_advisor_time_window.lua.rc
(27.29 KiB) Downloaded 1093 times


The Strategy was revised and updated on November 22, 2018.
Attachments
2018-11-22_08-47-14.png
2018-11-22_08-47-27.png
Last edited by Alexander.Gettinger on Fri Mar 02, 2012 4:14 pm, edited 1 time in total.
Alexander.Gettinger
FXCodeBase: Confirmed User
 
Posts: 3785
Joined: Wed Mar 31, 2010 9:40 pm
Location: Russia, Omsk

Re: Standard MA advisor strategy with trade time window

Postby surfandturf » Sat Jan 28, 2012 3:09 pm

Dear Alexander,
I can not load this file. Something is wwrong. I can load all other Strategies without problems. Please advice.
surfandturf
 
Posts: 25
Joined: Mon Jan 09, 2012 10:16 am

Re: Standard MA advisor strategy with trade time window

Postby Apprentice » Sun Jan 29, 2012 1:52 pm

Did you download both files.
.Lua and Llua.RC
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36435
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Standard MA advisor strategy with trade time window

Postby juul66 » Tue Feb 07, 2012 8:34 am

Hi,

I have downloaded both files however the strategy is not working. The extension 'rc' is not recognized by TSII.

I have uploaded a print screen.

Could you please help ? Thanks you.
Attachments
error.jpg
juul66
 
Posts: 1
Joined: Tue Feb 07, 2012 8:27 am

Re: Standard MA advisor strategy with trade time window

Postby surfandturf » Fri Feb 10, 2012 10:51 am

Same with me!!! Please help, I even tried to review the code. Thanks for fast reply.
surfandturf
 
Posts: 25
Joined: Mon Jan 09, 2012 10:16 am

Re: Standard MA advisor strategy with trade time window

Postby Apprentice » Sun Feb 12, 2012 4:46 am

During testing i found small bug in this strategy.
But it was not your problem.
You do not need to load rc.lua.
The trading platform will do it alone,
If both files are in the same directory.
Just load. Lua file.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36435
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Standard MA advisor strategy with trade time window

Postby surfandturf » Sun Feb 12, 2012 8:35 am

Hello,
it still doesn't work. Mistake :344 first parameter needs to be a number, when trying to backtest. Please, explain how to correctly download this file. Is this a standard strategy and do we have to download into the standard folder. If yes, is it sufficient to copy the file in this folder. For custom strategies I usually load them via Marketscope/Signal Custom/Signals and Strategies.

Thanks
surfandturf
 
Posts: 25
Joined: Mon Jan 09, 2012 10:16 am


Re: Standard MA advisor strategy with trade time window

Postby surfandturf » Tue Feb 14, 2012 9:51 am

Dear Apprentice,
thanks! It works now. For the beauty contest you could add the new added parameters from the Time Frame also to the RC File, like this it will be translated in the according language. An option to choose the local time in the window would be nice for everybody who is not living in NY.

More importantly, I found a severe bug in the backtesting tool (only, and not in the regular charts). The columne for ask and bid in the history log is switched, as well as in the chart!!! The ask price must be always higher than the bid price, which is not the case in the backtesting tool. The calculation according to the strategy is actually correct, but since the columns are exchanged it will deliver the wrong output (equity, balance). Wow, fatal... Therefore the generated results in this strategy (or in all other strategies?) are not correct. Please, try to fix this as soon as possible.

Further, I found that there is a difference in MMR requirement depending, if I backtest in the Real or Demo account. The MMR is a factor 4 higher in the Demo account using the same settings. I have no clue why this is so, but it gives me trouble depending on which strategy I am testing, I get to early a MC.

It would also be very helpful to have the used margin by the open trades subtracted from the equity or at least also shown graphically besides the equity and balance.

Thanks, for helping
surfandturf
 
Posts: 25
Joined: Mon Jan 09, 2012 10:16 am

Re: Standard MA advisor strategy with trade time window

Postby surfandturf » Sat Feb 25, 2012 3:45 am

Dear Apprentice,
the MA Advisor with trade time window doesn`t work in when using it as a signal (automated mode). The error message is 344: The first parameter needs to be a number. Please correct. Before I have used it only in the backtesting modus.

Further, according to my last post on Feb. 14th there is a severe bug in the backtesting modus, can you reply, if you are are working on it and until when this problem is fixed?

Thanks
surfandturf
 
Posts: 25
Joined: Mon Jan 09, 2012 10:16 am

Next

Return to Custom Strategies

Who is online

Users browsing this forum: No registered users and 14 guests

cron