Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Useing a Data Series

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

    Useing a Data Series

    I've created the data series and this code below now works to take a trade:-

    if GetCurrentAsk() > eave3d[0])

    BUT THIS BELOW which I would prefer to use will not although it will compile it does not activate any trades, do you have any ideas why this is or if I have done something substantially wrong. The price is definately crossing above the level of eave3d?

    CrossAbove(GetCurrentAsk(), eave3d[0], 1) - I'm wanting it to take a trade if the ask crosses ubove the level of eave3d.

    #2
    Can you try

    CrossBelow(eave3d[0], GetCurrentAsk(), 1)

    make a difference?
    RayNinjaTrader Customer Service

    Comment


      #3
      No this won't compile now and neither will it the other way round I must have had it slightly different before any more ideas?

      Comment


        #4
        Sorry,

        Should be:

        CrossBelow(eave3d(), GetCurrentAsk(), 1)
        RayNinjaTrader Customer Service

        Comment


          #5
          I'll get it right in the end, this is the correct code i.e. it actually compiles but it will not take a trade despite being vivibly actionable on the chart?

          CrossBelow(GetCurrentBid(), eave3d, 1))

          Comment


            #6
            Debug it.

            Print out the GetCurrentAsk() values and the series value, see what is happening etc...
            RayNinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by traderqz, Yesterday, 04:32 PM
            1 response
            10 views
            0 likes
            Last Post NinjaTrader_Gaby  
            Started by f.saeidi, Today, 05:56 AM
            1 response
            4 views
            0 likes
            Last Post Jltarrau  
            Started by Jltarrau, Today, 05:57 AM
            0 responses
            4 views
            0 likes
            Last Post Jltarrau  
            Started by Stanfillirenfro, Yesterday, 09:19 AM
            7 responses
            52 views
            0 likes
            Last Post NinjaTrader_Gaby  
            Started by TraderCro, 04-12-2024, 11:36 AM
            4 responses
            71 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Working...
            X