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

historical vs. not historical

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

    historical vs. not historical

    I have two similar indicators. I want both to be historical but only one is. I think I've narrowed it down to this:

    This is historical:

    (DelPlaced[0] >= DelPlaced[1] && DelPlaced[1] < DelPlaced[2] && DelPlaced[2] < DelPlaced[3])
    This is NOT historical (does not stay on my chart after refresh):

    (DeltaPlaced[0] > 0 && DeltaPlaced[1] > 0 && DeltaPlaced[2] < 0 && DeltaPlaced[3] < 0)
    The pos and neg numbers are important, but it doesn't work when equate to zero.

    Does anyone know how to fix this?

    Thank you.

    #2
    Hello imalil, and thank you for your question.

    I believe, without being able to see the content of your indicators or your own NinjaScript, that DelPlaced works with historical data, while DeltaPlaced does not. You can verify for yourself with this code. You will want to open a Tools -> Output Window (or New -> NinjaScript Output in NT8) to view the output of this code.

    Code:
    [FONT=Courier New]for(int i = 0; i < 4; i++)
    {
      Print("DelPlaced[" + i + "] = " + DelPlaced[i]);
      Print("DeltaPlaced[" + i + "] = " + DeltaPlaced[i]);
    }[/FONT]
    Please let us know if there is any other way we can help.
    Jessica P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by josh18955, 03-25-2023, 11:16 AM
    6 responses
    435 views
    0 likes
    Last Post Delerium  
    Started by FAQtrader, Today, 03:35 PM
    0 responses
    3 views
    0 likes
    Last Post FAQtrader  
    Started by rocketman7, Today, 09:41 AM
    5 responses
    18 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by frslvr, 04-11-2024, 07:26 AM
    9 responses
    127 views
    1 like
    Last Post caryc123  
    Started by selu72, Today, 02:01 PM
    1 response
    14 views
    0 likes
    Last Post NinjaTrader_Zachary  
    Working...
    X