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

weekly RSI

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

    weekly RSI

    hi all - is it possible to develop a 'weekly RSI' in NT? and if so, how would i go about it?

    the weekly RSI is to use the close price of the last day of the trading week (in most cases this would be the Friday, but could be Thursday if Friday is public holiday).
    the weekly RSI is then combined with the normal (daily) RSI on a daily chart
    the basis of the model is to enter long for a high reading of weekly RSI and low reading for daily RSI.

    in addition, could this be converted into a 'monthly RSI'?

    thanking you in advance for your time - best regards...

    ...jurgen

    #2
    Hi Jurgen, yes that would be possible in a so called MultiSeries script, where you add other timeframes in and then could run indicator calculations on those instead of the primary series you're working on. So you could combine the daily, weekly and monthly frames in one script to arrive at signals.

    We ship NT with an example script you could review to get started, it's called 'SampleMultiTimeFrame'.

    The full framework would be showcased here in our helpguide -

    BertrandNinjaTrader Customer Service

    Comment


      #3
      Originally posted by jurgenC View Post
      hi all - is it possible to develop a 'weekly RSI' in NT? and if so, how would i go about it?

      the weekly RSI is to use the close price of the last day of the trading week (in most cases this would be the Friday, but could be Thursday if Friday is public holiday).
      the weekly RSI is then combined with the normal (daily) RSI on a daily chart
      the basis of the model is to enter long for a high reading of weekly RSI and low reading for daily RSI.

      in addition, could this be converted into a 'monthly RSI'?

      thanking you in advance for your time - best regards...

      ...jurgen

      There are four solutions to your question. I will respond via four separate posts.

      Solution 1:

      Displaying daily and weekly RSI on your chart does not require any coding. Open a daily chart, then add weekly bars on the first panel, set the weekly bars to transparent and apply the RSI both to the daily bars and then again to the weekly bars. Chart attached.
      Attached Files

      Comment


        #4
        Solution 2:

        It is possible to calculate composite bars from single bars. For example you can regroup 5 single bars to build a composite bar, and then perform the indicator calculations on composite bars. The best approach here is to calculate the RSI from rolling composite bars. A five day rolling RSI is similar, but not identical to a weekly RSI.

        A second bar series is not required as the indicator code takes care of the problem. This approach is well suited for automated strategies, The rolling 5-day values can be used as trigger signals, without dealing with complex multibar series problems.

        A sample chart is attached below.
        Attached Files

        Comment


          #5
          Solution 3:

          You can simply tweak the indicator formula of the RSI to allow for calculating it from a higher timeframe.
          This approach is similar to the use of rolling composite bars, but instead of calculating bars, simply input parameters and the formula of the RSI are modified.

          I have recently done this with the MACD. Below is a sample chart with three different timeframes in overlay mode.

          -> daily (blue)
          -> 5-daily (white) approximates weekly
          -> 20-daily (gold) approximates monthly

          The same approach is possible with the RSI.
          Attached Files
          Last edited by Harry; 06-11-2013, 01:20 PM.

          Comment


            #6
            Solution 4:

            Solutions 2 and 3 provide for a good an simple substitute of a weekly RSI. They are even more timely than the weekly RSI, as they are based on rolling 5 business day.

            However, for unknown reasons, you might want to use a genuine weekly RSI. In that case you have still two options

            - either retrieve the data required for calculating the weekly RSI each Friday, store that data in an array and use it to calculate the RSI

            - or add a weekly bar series to your indicator and then use an instance of the RSI that accesses this bar series

            I would definitely use the option 1, as the calculations are not CPU intensive and as it will be more stable.

            Comment


              #7
              hi Harry...

              ...thank-you very much for such comprehensive replies; i appreciate your time & effort that you invested into this.

              with best regards...

              ...jurgen

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by halgo_boulder, 04-20-2024, 08:44 AM
              2 responses
              21 views
              0 likes
              Last Post halgo_boulder  
              Started by mishhh, 05-25-2010, 08:54 AM
              19 responses
              6,189 views
              0 likes
              Last Post rene69851  
              Started by gwenael, Today, 09:29 AM
              0 responses
              5 views
              0 likes
              Last Post gwenael
              by gwenael
               
              Started by Karado58, 11-26-2012, 02:57 PM
              8 responses
              14,830 views
              0 likes
              Last Post Option Whisperer  
              Started by Option Whisperer, Today, 09:05 AM
              0 responses
              2 views
              0 likes
              Last Post Option Whisperer  
              Working...
              X