Hi,
I applied on a weekle chart a strategy and then I tried to use Bar Magnifier to see the result based on daily data but the result are the same... it seems that dosn't works.
How I did:
in Strategy Properties-->Backtesting I flag Use Bar Magnifier and then flag Daily.
Riccardo
Backtesting Precision & Bar Magnifier
- Henry MultiСharts
- Posts: 9165
- Joined: Aug 25 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Hello Riccardo,
Do you consider that the strategy calculation results should be different using 1 day bar magnifier?
Please describe in details.
Do you consider that the strategy calculation results should be different using 1 day bar magnifier?
Please describe in details.
Hello Henry,
I use stop order on weekly data. If I don't use Bar Magnifier I have execution price to levels that would have been untouched. When I use Bar Magnifier I would expect a execution price only at real price touched in daily data.
In attachment the example chart where I buy at open + x stop. I applied Bar Magn. but the price of execution is never touched on daily data.
Thanks
Riccardo
I use stop order on weekly data. If I don't use Bar Magnifier I have execution price to levels that would have been untouched. When I use Bar Magnifier I would expect a execution price only at real price touched in daily data.
In attachment the example chart where I buy at open + x stop. I applied Bar Magn. but the price of execution is never touched on daily data.
Thanks
Riccardo
- Attachments
-
- CHART.png
- (106.67 KiB) Downloaded 725 times
- Henry MultiСharts
- Posts: 9165
- Joined: Aug 25 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Hello Riccardo,
1) All highlighted in orange trades took place within a bar. Do you have any orders executed at price beyond High or Low of a bar?
If yes, please demonstrate this bar with visible hint window.
Please have a look at the attachment.
2) Are you using Extended Backtesting mode with 2 extra data series (asks/bids)?
3) Please explain what is incorrect in the Strategy performance report.
1) All highlighted in orange trades took place within a bar. Do you have any orders executed at price beyond High or Low of a bar?
If yes, please demonstrate this bar with visible hint window.
Please have a look at the attachment.
2) Are you using Extended Backtesting mode with 2 extra data series (asks/bids)?
3) Please explain what is incorrect in the Strategy performance report.
- Attachments
-
- Pic1.png
- (161.8 KiB) Downloaded 709 times
- JoshM
- Posts: 2196
- Joined: May 20 2011
- Location: The Netherlands
- Has thanked: 1544 times
- Been thanked: 1565 times
- Contact:
Your problem might lay in your code:Henry in attachment the explain.
Code: Select all
buy next bar at open + value1 stop;
For example, let's say value1 is 10, and the current price is 2.498:
- Bar 1 opens at 2.499 -> buy order submitted at 2.509,
Bar 2 opens at 2.502 -> buy order submitted at 2.512,
Bar 3 opens at 2.499 -> buy order submitted at 2.509,
etc.
Perhaps something like this might work better:
Code: Select all
Variables:
enterLong(False), elPrice(0);
if (Close > XAverage(Close, 20)) then begin
enterLong = True;
elPrice = Open + 10;
end;
if (enterLong = True) then
buy next bar at elPrice stop;
Thanks Josh for the help!
The code isn't
buy next bar at open + value1 stop;
but
buy next bar at open next bar + value1 stop;
Josh I would buy tomorrow at open + value1 (calculated today).
I tried in TS and works (pheraps the code is little bit different)
easylanguage TS 2000i:
buy at o next bar + value1 stop;
In format strategy Backtesting Setting I flag Strategy testing resolution on daily and works.
easylanguageMC 7.4:
buy next bar at open next bar + value1 stop;
I flag daily resolution but don't work
The code isn't
buy next bar at open + value1 stop;
but
buy next bar at open next bar + value1 stop;
Josh I would buy tomorrow at open + value1 (calculated today).
I tried in TS and works (pheraps the code is little bit different)
easylanguage TS 2000i:
buy at o next bar + value1 stop;
In format strategy Backtesting Setting I flag Strategy testing resolution on daily and works.
easylanguageMC 7.4:
buy next bar at open next bar + value1 stop;
I flag daily resolution but don't work
- Henry MultiСharts
- Posts: 9165
- Joined: Aug 25 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
There is no hint on the chart that makes price comparison impossible.
Please enable the hint in View->Show hint and Tracking time and price in View->Tracking settings and provide proper screenshots with visible hint or data window.
Please further note that full screenshots are preferred as the cropping is removing necessary information.
You can also come to our live chat Monday-Friday 6:30 am - 4 pm EST to demonstrate the issue live.
We will do our best to help you.
Please enable the hint in View->Show hint and Tracking time and price in View->Tracking settings and provide proper screenshots with visible hint or data window.
Please further note that full screenshots are preferred as the cropping is removing necessary information.
You can also come to our live chat Monday-Friday 6:30 am - 4 pm EST to demonstrate the issue live.
We will do our best to help you.
Henry, The correct price filled is fundamental during backtesting. When I test a strategy i must know if is really profitable or if the order generated are filled at inesistent price (during gAp). In TS backtesting resolution works in this manner. Sure I prefere MC, but this is a problem in backtesting. Could MC staff modify backtester resolution and bar magnifire to have a result nearest to reality? Nobody have my problem?
- Henry MultiСharts
- Posts: 9165
- Joined: Aug 25 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Riccardo, we are investigating this case.
I will keep you updated.
I will keep you updated.
- Henry MultiСharts
- Posts: 9165
- Joined: Aug 25 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Hello Riccardo,
Currently MultiCharts uses only the close of the detailed data series bar and applies Intra-Bar Price Movement Assumptions for calculation. We agree that this is malfunction.
This functionality will be improved in one of the future versions of MultiCharts. Strategy will be calculated on the OHLC of the detailed data series bar using Intra-Bar Price Movement Assumptions, avoiding order fill in the price gaps.
Thank you for the reporting.
Currently MultiCharts uses only the close of the detailed data series bar and applies Intra-Bar Price Movement Assumptions for calculation. We agree that this is malfunction.
This functionality will be improved in one of the future versions of MultiCharts. Strategy will be calculated on the OHLC of the detailed data series bar using Intra-Bar Price Movement Assumptions, avoiding order fill in the price gaps.
Thank you for the reporting.
Ok Henry,
Please to cosider to extend Bar Magnifier and the improvement to Portfolio Backtester too. Portfolio Backtester is a formidable tool (global variable like Portfolio.netprofit are very useful!!) and one (with many other) of the benefit to work with MC.
I am glad that my report is served!!
Riccardo
Please to cosider to extend Bar Magnifier and the improvement to Portfolio Backtester too. Portfolio Backtester is a formidable tool (global variable like Portfolio.netprofit are very useful!!) and one (with many other) of the benefit to work with MC.
I am glad that my report is served!!
Riccardo
- Henry MultiСharts
- Posts: 9165
- Joined: Aug 25 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Riccardo,
Thank you for your suggestion.
We will consider the implementation of this feature in one of the future versions.
Thank you for your suggestion.
We will consider the implementation of this feature in one of the future versions.