Trade is shown in backtest Price chart but not Equity Curve

Viewing 15 posts - 1 through 15 (of 23 total)
  • Author
    Posts
  • #142730 quote
    teapot2002
    Participant
    Average

    I was alerted to this by a live trade that failed. When I went to backtest this trade to see what went wrong I noticed that it is shown on the Price graph, but not in the Equity Curve at the top, and not in the Detailed Report, as you can see in the screenshots.

    The first screenshot shows the bigger picture going back to 29 April. You’ll see a number of trades on the Price chart that match those in the Detailed Report. However, the final trade (where the cursor is) on the Price chart, on 25 August, isn’t shown in the  Closed Positions List and isn’t shown in the Equity chart above the Price chart.

    The second screenshot shows this trade zoomed in. Again, you can see it on the Price chart, but not elsewhere.

    I am running this live, and the trade failed as I show in the third screenshot – this matches the Price chart in backtesting, but this time the Equity chart shows it losing.

    I am worried that the backtest Closed Position List doesn’t show all the trades, and that some could be failing but I wouldn’t see them unless I checked all the graphed trades against the Closed Position List.

    Could you please shed some light on this?

    Thanks.

    Screenshot-2020-08-27-at-16.19.43.png Screenshot-2020-08-27-at-16.19.43.png Screenshot-2020-08-27-at-16.21.57.png Screenshot-2020-08-27-at-16.21.57.png Screenshot-2020-08-27-at-16.23.27.png Screenshot-2020-08-27-at-16.23.27.png
    #142753 quote
    GraHal
    Participant
    Master

    May not be relevant, but what spread value did you set in the backtest engine?

    #142757 quote
    GraHal
    Participant
    Master

    isn’t shown in the  Closed Positions List

    Is it shown in the Orders List or the Cancelled / Rejected List>

    #142759 quote
    teapot2002
    Participant
    Average

    Thanks for the response, GraHal. In reply:

    It’s not in the orders list, attached. Do I have a Cancelled / Rejected list for backtesting?

    Spread is 2pts, although if I untick the box I get the same problem, just with a slightly better total in the Equity Curve – attached.

    Screenshot-2020-08-27-at-20.16.55.png Screenshot-2020-08-27-at-20.16.55.png Screenshot-2020-08-27-at-20.19.42.png Screenshot-2020-08-27-at-20.19.42.png
    #142765 quote
    GraHal
    Participant
    Master

    Do I have a Cancelled / Rejected list for backtesting?

    No … me getting confused, one eye on the TV again! 🙂

    #142766 quote
    GraHal
    Participant
    Master

    Even if the 7th / invisible order was a 0 / zero bars trade (open and close in same bar) then it should still show in the Closed Trades list … very strange!

    #142813 quote
    Nicolas
    Keymaster
    Master

    There is something odd as your backtest has an end date on 27th April, while the last order is opened and closed the 29th! Do you confirm?

    #142820 quote
    GraHal
    Participant
    Master

    I see bt ending on 27 Aug and the trade opened on 25 Aug.

    #142826 quote
    teapot2002
    Participant
    Average

    Nicholas – I read it that backtesting in screenshots 1 and 2 is from 19 April – 27 August. The trades are from 29 April – 5 June.

    #142834 quote
    Nicolas
    Keymaster
    Master

    Ok sorry, i wrongly read the backtest end date.

    I can’t replicate without the code and see what’s going on on that particular system. In that case, I suggest you send a technical report through the platform and wait for an answer.

    #142835 quote
    teapot2002
    Participant
    Average

    I have just tried backtesting this again, changing only the number of units: 100,000, then 10,000, then 1,000 units. I attach the screenshots from the results. They are anomalous.

    There are several more trades in July and August that show when backtested with smaller number of units than 100,000, but not when tested with 100,000 units. Compare the screenshot for 10,000 with the originally posted one for 100,000. Even with 10,000 units the 25 August trade isn’t shown in the Equity Curve and Closed Position list, although it is on the Price chart. I also don’t understand why it’s shown with red and green markers, when the other trades are in blue and yellow.

    This 25 August trade is shown correctly when 5,000 units are displayed, and now with blue and yellow markers like the other trades.

    Screenshot-2020-08-28-at-14.23.06.png Screenshot-2020-08-28-at-14.23.06.png Screenshot-2020-08-28-at-14.24.16.png Screenshot-2020-08-28-at-14.24.16.png Screenshot-2020-08-28-at-14.27.24.png Screenshot-2020-08-28-at-14.27.24.png Screenshot-2020-08-28-at-14.29.23.png Screenshot-2020-08-28-at-14.29.23.png
    #142840 quote
    teapot2002
    Participant
    Average

    Nicholas, I was writing my last post as you posted. I have just submitted a report as you suggest. Thanks.

    #142842 quote
    Nicolas
    Keymaster
    Master

    Well … keep us update!

    #142849 quote
    GraHal
    Participant
    Master

    I also don’t understand why it’s shown with red and green markers, when the other trades are in blue and yellow.

    Usually that would be red and green markers attributable to one System and blue and yellow markers attributable to another system … so might you have 2 systems running?

    #142882 quote
    Vonasi
    Moderator
    Master

    Red and green arrows are trades that have been opened and closed by strategies running live. Blue and yellow are those of a back test.

    GraHal and teapot2002 thanked this post
Viewing 15 posts - 1 through 15 (of 23 total)
  • You must be logged in to reply to this topic.

Trade is shown in backtest Price chart but not Equity Curve


Platform Support: Charts, Data & Broker Setup

New Reply
Author
author-avatar
teapot2002 @teapot2002 Participant
Summary

This topic contains 22 replies,
has 5 voices, and was last updated by Nicolas
5 years, 4 months ago.

Topic Details
Forum: Platform Support: Charts, Data & Broker Setup
Language: English
Started: 08/27/2020
Status: Active
Attachments: 15 files
Logo Logo
Loading...