Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Problems with cTrader connection: Incorrect instrument properties, order misbehaviour

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Problems with cTrader connection: Incorrect instrument properties, order misbehaviour

    I was investigating an issue reported by a customer using cTrader and I discovered that when connecting through cTrader, the CFD instruments properties get overwritten with incorrect values.

    For example, the @EURUSD CFD instrument as modified by the cTrader connection get the following properties:​
    Click image for larger version

Name:	image.png
Views:	455
Size:	49.6 KB
ID:	1253484

    As we can see, the Currency is set to Euro which is not correct. It should be US Dollars.

    It seems the currency for all instruments available through cTrader get overwritten to Euro.
    When looking at the Quote asset from the Symbol info pane in cTrader the Quote asset currency matches what I’m expecting for all symbols I have validated here is a few example:
    Symbol cTrader Quote asset NinjaTrader Currency
    EURUSD USD Euro
    AUDCHF CHF Euro
    USDCAD CAD Euro
    EURGBP GBP Euro
    US500 USD Euro
    LUFTHANSA EUR Euro this one is good!!!
    APPLE USD Euro
    BTCUSD USD Euro
    BTCEUR EUR Euro this one is good!!!
    Click image for larger version

Name:	image.png
Views:	203
Size:	53.2 KB
ID:	1253485
    All the above CFD have the proper Currency with the default NinjaTrader installation before connecting to cTrader that overwrites the instruments definition.

    The point value is also incorrectly set for all cTrader Forex CFD and also some other CFD symbols. cTrader is accepting orders quantity in Forex micro lots meaning by multiple of 1000 units. The smallest size available in cTrader is 0.01 which represent 1000 units. The smallest Order quantity available in NinjaTrader is 1. So placing an EURUSD order of qty 1 from NinjaTrader will be equivalent to placing an order of qty 0.01 in cTrader. Therefore the Point value should be 1000. This will allow NinjaTrader to calculate the correct PnL.

    The Point value is also incorrect for Bitcoins (@BTCUSD @BTCEUR). cTrader smallest order is 0.01 Bitcoin so the Point value should be 0.01. This will allow to get the correct PnL from NinjaTrader, matching the PnL from cTrader.

    The Point value for NATGAS should be 100. The Point value for XTIUSD should be 10.

    I didn’t check other symbols so it’s possible that other changes to the Point value is required.

    Changing manually the values by editing the instrument is giving the adequate functionality but this is just temporary as cTrader will overwrite the changes on the next connection.

    I also get problems when I move a pending limit order (change the limit price). For example, with @BTCUSD if I place a pending order of Qty 1 from NinjaTrader, I get a pending order of Qty 0.01 in cTrader. But when moving that pending order on the NinjaTrader chart, the handshake between NT and cTrader changes to Qty to 100 which should not happen.
    Click image for larger version

Name:	Bitcoin.gif
Views:	220
Size:	230.8 KB
ID:	1253486
    And for @EURUSD when I place a pending limit order of Qty 1000 in NinjaTrader, the Qty is correctly set to 10 lots in cTrader but when moving that pending order in NinjaTrader, the Qty get changed to 1 which should not happen and if I move it again from NinjaTrader then I get an error message saying the minimum qty is 1000.
    Click image for larger version

Name:	EURUSD.gif
Views:	225
Size:	1,003.5 KB
ID:	1253487
    This is happening with a demo account created from Spotware and a fresh install of NinjaTrader 8.1.1.6.

    For now I have added special logic to my Position Sizing tool to allow the user to offset the Point value when using CFD instruments but I really consider that as a temporary patch and the problem should be corrected adequately by NinjaTrader. With the modification I made to My Position Sizing tool, the Entry quantity will be adequately calculated to match the user defined risk but NinjaTrader will show an erroneous PnL that will not match the PnL from the cTrader platform or the user account. And the quantity changing when moving a pending order needs to be fixed by NinjaTrader.

    Thank you​
    ASCENDO Trading
    NinjaTrader Ecosystem Vendor - ASCENDO Trading

    #2
    Hello,

    Thank you for your Post and your feedback.

    I have shared this with our Development Team to look into further.

    Please let me know if I may be of any further assistance.
    Dennis E.NinjaTrader Customer Service

    Comment


      #3
      Hello Dennis,

      Could you please provide an update. Was the Development Team able to reproduce the problem? Is there an ECD to get it resolved?

      Thank you
      ASCENDO Trading
      NinjaTrader Ecosystem Vendor - ASCENDO Trading

      Comment


        #4
        Hello,

        Thank you for the reply

        I have requested an update from our Technology team and will follow up shortly.

        Thank you for your patience.
        Dennis E.NinjaTrader Customer Service

        Comment


          #5
          Hello Dennis,

          Do you have an update on this issue yet?

          I have the same exact problem using ChangeOrder() connected to cTrader. Basically, when I setup a OCO submitting quantity = 1 cTrader responds ACCEPTED but with quantity = 100 which is wrong clearly wrong. This only happens with the STOP order side of the OCO, however with the PROFIT LIMIT OCO the quantity = 1 is working.

          I believe the issue is with a wrong implementation of NT ChangeOrder() that is not aligned with cTrader ModifyPosition(position, stopLoss, position.TakeProfit). ChangeOrder() requires the order itself as the first parameter, however cTrader ModifyPosition () does require the actual volume/quantity, hence the issue.

          Thank you

          Comment


            #6
            Hello again,

            A rectification to my previous post, the issue happens for both the pending limit and the stop loss orders and when using ChangeOrder() method in the NT script connected to cTrader.

            Comment


              #7
              I have sent our Development Team a note to see if there are any updates available regarding this issue and I will follow up once I have additional information available.
              Christopher J.NinjaTrader Customer Service

              Comment


                #8
                Any news from the dev team yet? I think it´s taking a long time to respond whether is or isn´t a bug even

                Thanks!

                Comment


                  #9
                  Our development team is currently working with cTrader on a resolution to this issue. I will post a follow up once I receive confirmation this has been resolved.
                  Christopher J.NinjaTrader Customer Service

                  Comment


                    #10
                    Hello NT team
                    any update to the subject ? I want connect FTMO via Ctrader to NT8. Please let me know if it is possible.
                    Thank you

                    Comment


                      #11
                      Our development team is still working with Ctrader regarding this case.

                      Again thank you for your patience.
                      Christopher J.NinjaTrader Customer Service

                      Comment


                        #12
                        Hi NT,
                        Any updates on this issue yet or at least an ETA to resolve it? the biggest problem for me at least is with the wrong quantity allocated when changing a pending order as described by ASCENDO at the beginning of this thread. If there isn´t a workaround I think this bug should be on top the priority list to fix by NT, I can´t run my strategy in cTrader like that.

                        Thanks!

                        Comment

                        Latest Posts

                        Collapse

                        Topics Statistics Last Post
                        Started by aligator, 01-06-2022, 12:14 PM
                        3 responses
                        227 views
                        0 likes
                        Last Post aligator  
                        Started by reynoldsn, Today, 05:56 PM
                        0 responses
                        1 view
                        0 likes
                        Last Post reynoldsn  
                        Started by bortz, 11-06-2023, 08:04 AM
                        51 responses
                        1,986 views
                        0 likes
                        Last Post aligator  
                        Started by dmking, 11-12-2019, 12:31 PM
                        4 responses
                        4,143 views
                        0 likes
                        Last Post jasonw
                        by jasonw
                         
                        Started by roblogic, Today, 04:31 PM
                        0 responses
                        10 views
                        0 likes
                        Last Post roblogic  
                        Working...
                        X