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

loading & processing required number of bars for multi-time

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

    loading & processing required number of bars for multi-time

    I want to use information from many previous days (say SMA(20) on close of day) on a small scale chart (say 1 minute).

    Problem1: I need to specify "days to load" > 20 (on primary series) to get 20 day bars to load. For instance if I specify 20 it may only actually load say 12 bars (due to non-trading days). This means the SMA(20) will be inaccurate since it will really be giving figure for say SMA(12).

    Problem 2: Even if I specify a large enough "days to load" (say 32) to get 20 day bars loaded, there is still the problem I don't want to fill up memory with 20 trading days worth of minute bars (even worse if I was using seconds or ticks), I only really want no more than the last day's worth of this. So is there some way of forcing the load/processing of an added long-duration period series, without loading the full equivalent calendar length of bars in the base short-duration series?

    Possible solution:
    NT adds another parameter (say "BarsToLoad") to the Add method. So instead of currently using
    Code:
    Add(PeriodType.Day,1);
    to add an unknown number of day bars, I could use
    Code:
    Add(PeriodType.Day,1,20);
    (where the last parameter is suggested "BarsToLoad").

    When this new method was used NT would call OnBarUpdate for each of the requested number of BarsToLoad on the long-duration series (even if there was only a day or less of short-duration primary bars loaded).

    #2
    Hi DaveE,

    Thank you for your input regarding enhancing NinjaTrader; we will track your feedback using ID# 1280.
    Ryan M.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by MarianApalaghiei, Today, 10:49 PM
    1 response
    8 views
    0 likes
    Last Post NinjaTrader_Manfred  
    Started by love2code2trade, Yesterday, 01:45 PM
    4 responses
    28 views
    0 likes
    Last Post love2code2trade  
    Started by funk10101, Today, 09:43 PM
    0 responses
    8 views
    0 likes
    Last Post funk10101  
    Started by pkefal, 04-11-2024, 07:39 AM
    11 responses
    37 views
    0 likes
    Last Post jeronymite  
    Started by bill2023, Yesterday, 08:51 AM
    8 responses
    46 views
    0 likes
    Last Post bill2023  
    Working...
    X