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

Muti- datasries with renko bars

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

    Muti- datasries with renko bars

    Hi Ninja team,
    I'm testing a strategy but facing a tricky issue, the strategy is based on renko bars crossover, it's more scalping strategy. I want to apply to it a long trend filter using Gaussian filter or DEMA (doesn't matter the indicator as it have the same weird behaviour) the issue is that filter rendering is completely different than the one taken alone (gaussian filter hidden in te picture)

    Click image for larger version

Name:	image.png
Views:	90
Size:	182.0 KB
ID:	1289124
    In the script besides main data serie (renko), I add 60 minutes data serie, i use this second data serie as input to the filtering MA

    AddDataSeries(Data.BarsPeriodType.Minute, 60);
    ...

    // USE BarsArray[1] to get the secondary dataseries

    AuDema1 = AuDEMA(BarsArray[1], 100);
    AuDema1.Plots[0].Brush = Brushes.DeepSkyBlue;
    AuDema1.Plots[1].Brush = Brushes.Transparent;
    AddChartIndicator(AuDema1);​

    and than using the trend data to filter...

    if (BarsInProgress == 1)
    {
    if (AuDema1.Trend[0] ==1)
    currentTrend = true;
    else
    currentTrend = false;
    }​

    the issue as you can see, even if I use equidistant time axies and even with different types (replace renko by 15 min candlesticks) the indicator caluted value seems always wrong except if the main datasherie match the secondary dataserie which make the second one useless

    What could be the reason for this mismatch

    Thanks for your help

    #2
    Hello bourasrafik,

    From the image it is hard to tell what you are trying to show is the problem, are you saying that the indicator calculated differently when using it with a different series? if so that would be expected if the indicator has any change in data it may come to a different calculated value based on the new dataset it used.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Hi Jesse,
      What I meant is when I apply the indicator directly to the daily candlestick data (image in the bottom), the calculated value is different from the one applied as secondary data serie with the same parameters (daily candlesticks) its the top image, as you know the secondary series cannot displayed.
      I expect that both calculation is the same in direct apply or through applying it to added data series
      Thanks

      Comment


        #4
        Hello bourasrafik,

        That is going to depend on the secondary series and what data was loaded. To know that you are doing the exact same calculation you would need to use prints and make sure the exact same days were processed.
        JesseNinjaTrader Customer Service

        Comment


          #5
          Thanks Jesse, I will check that

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by llanqui, Today, 10:32 AM
          0 responses
          1 view
          0 likes
          Last Post llanqui
          by llanqui
           
          Started by StockTrader88, 03-06-2021, 08:58 AM
          45 responses
          3,992 views
          3 likes
          Last Post johntraderuser2  
          Started by TAJTrades, Today, 09:46 AM
          0 responses
          7 views
          0 likes
          Last Post TAJTrades  
          Started by rhyminkevin, Yesterday, 04:58 PM
          5 responses
          62 views
          0 likes
          Last Post dp8282
          by dp8282
           
          Started by realblubb, Today, 09:28 AM
          0 responses
          8 views
          0 likes
          Last Post realblubb  
          Working...
          X