NexusFi: Find Your Edge


Home Menu

 





daily 5-day-SMA on 5-minute chart.


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one tranta with 4 posts (2 thanks)
    2. looks_two Tasker_182 with 3 posts (2 thanks)
    3. looks_3 Fat Tails with 2 posts (8 thanks)
    4. looks_4 Silvester17 with 1 posts (3 thanks)
      Best Posters
    1. looks_one Fat Tails with 4 thanks per post
    2. looks_two Silvester17 with 3 thanks per post
    3. looks_3 trendisyourfriend with 2 thanks per post
    4. looks_4 Tasker_182 with 0.7 thanks per post
    1. trending_up 10,120 views
    2. thumb_up 19 thanks given
    3. group 6 followers
    1. forum 15 posts
    2. attach_file 8 attachments




 
 

daily 5-day-SMA on 5-minute chart.

 
 
kronie's Avatar
 kronie 
NYC + NY / USA
 
Experience: Advanced
Platform: "I trade, therefore, I AM!"; Theme Song: "Atomic Dog!"
Trading: EMD, 6J, ZB
Posts: 796 since Oct 2009


gfmatt View Post
If you want to keep things simple you can just convert a 5 sma on a daily to the 5 minute chart :

There are twelve 5 minute periods per one hour multiplied by twenty-four hour per day multiplied by five days (12x24x5 = 288)

So a daily 5 SMA is roughly equivalent to a 288 SMA on a five minute chart (assuming your chart is a 24hr chart). Only a few ticks difference between them.

why do you multiply by the 5 days?, if this is going to be a "true" 5 sma daily?


Can you help answer these questions
from other members on NexusFi?
How to apply profiles
Traders Hideout
MC PL editor upgrade
MultiCharts
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
What broker to use for trading palladium futures
Commodities
 
 
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,467 since Jun 2009
Thanks Given: 33,244
Thanks Received: 101,669


futurestrader1 View Post
Is there a Daily SMA available as a free indicator for NinjaTrader? I would love to see it!

AFAIK, all you need to do is add a second dataseries (daily) to your chart, then hide it, then add a SMA and select that data series as the source. I'm sure an NT user could confirm, or @Fat Tails, @cory or @Silvester17 might know a better way.

Mike



Join the free Markets Chat beta: one platform, all the trade rooms!

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal
Thanked by:
 
 
trendisyourfriend's Avatar
 trendisyourfriend 
Quebec Canada
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader
Broker: AMP/CQG
Trading: ES, NQ, YM
Frequency: Daily
Duration: Minutes
Posts: 4,527 since Oct 2009
Thanks Given: 4,176
Thanks Received: 6,020


Try any of these two's :




Thanked by:
 
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,103


futurestrader1 View Post
It would be nice if the 288SMA would be the same on a 5min chart as a true daily sma on a same chart.
I use NT and ThinkOrSwim. TOS has a Daily SMA indicator built in and it is awesome. Why doesn't NT have it also.

The use of the Daily SMA is what Brian Shannon uses for his day trading and it is a great aid.

Is there a Daily SMA available as a free indicator for NinjaTrader? I would love to see it!


A SMA(288) cannot be the same as a daily SMA, unless the instrument is traded for 24 hours without technical breaks. For example ES is traded from 5:00 PM to 3:15 PM and then from 3:30 PM to 4:15 PM, which makes up for 276 5-minute bars. Another problem is that the SMA(276) would recalculate every 5 min, and therefore represent a rolling day, whereas the daily SMA is only calculated once per day after the close.

Daily data is only available with a few minutes of lag, therefore the daily SMA will not be available immediately after the close.

When applying a daily SMA to an intraday chart it is important to specify, what you wish to calculate the daily SMA from! This could be

-> the settlement price (needs a data supplier that gives you the settlement price)
-> the regular close
-> the full session close

The next question what you wish to display on your chart

-> the SMA calculated from yesterday's close (you can display it as horizontal line)
-> or an estimate for today's SMA based on the last traded price


Calculating yesterday's SMA

This can be either done by using daily data (close or settlement price) or intraday data (regular close or full session close). Yesterday's value of the SMA can be displayed as a horizontal line for today.


Calculating today's SMA

The problem here is that today's SMA is not known prior to the market close (either regular or full session close). Therefore today's SMA would need to be calculated from the prior closes (final values) and the last traded price (best approximation for today's expected close). The prior closes can be taken from daily data, while the last traded price is always taken from intraday data.


In the end the best solution depends on what you look for and which data feed you use.

Thanked by:
 
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,103


trendisyourfriend View Post
Try any of these two's :





I did not think about this option, but @trendisyourfriend is correct here. The VisualSMA can be used to produce a daily moving average from intraday data. However, there are a few prerequisites:


(1) The VisualSMA will not work correctly on charts with non-equidistant bar spacing, so you should only apply it to a chart with a single bar series.

(2) The VisualSMA loads a secondary bar series, which is used for the purpose of calculating the SMA. If you set it to 1440 min, it will load a secondary bar series with 1 bar (1440 min or less) per session. It is important to understand that NinjaTrader cuts off all bars at the end of the session. Therefore you should use a pure ETH or RTH session template and not a template with subdivided sessions. In that case the VisualSMA will display a daily SMA calcuated from the last traded price of that session.

(3) With an ETH session template you will get a SMA calculated from the full session close. With the RTH session template you will get a SMA calculated from the regular session close. If you use a complex session template with 3 subsessions per day, then you need to adapt the period of the SMA. A daily SMA(20) can be approximated with a VisualSMA(60) on a complex session template with 3 subsessions.


Below is a chart which shows the VisualSMA(20) which simulates a daily SMA. I have set the indicator to COBC = false to reflect the last traded price. The daily SMA(20) is shown as 1920.88. This is in fact the EXACT VALUE of the daily SMA(20) calculated from the full session closes at 4:15 PM Central.

If you calculate the daily SMA(20) from the settlement prices, the result is 1921.34, which is two ticks off the SMA(20) calculated from the full session closes.



 
 
Silvester17's Avatar
 Silvester17 
Columbus, OH
Market Wizard
 
Experience: None
Platform: NT 8, TOS
Trading: ES
Posts: 3,603 since Aug 2009
Thanks Given: 5,139
Thanks Received: 11,527


futurestrader1 View Post
It would be nice if the 288SMA would be the same on a 5min chart as a true daily sma on a same chart.
I use NT and ThinkOrSwim. TOS has a Daily SMA indicator built in and it is awesome. Why doesn't NT have it also.

The use of the Daily SMA is what Brian Shannon uses for his day trading and it is a great aid.

Is there a Daily SMA available as a free indicator for NinjaTrader? I would love to see it!

a simple way would be to create an indicator with a second data series. similar to what the op posted.

with the attached indicator you can choose what time frame and period (sma). in the examples below it shows a 5 min chart with a 10 period sma from a 30 min chart and also from a 1440 min chart. for daily charts I recommend using a 1440 min chart. depending on your data supplier you might get different results with daily charts.





and if you set plot style to "hash", it should match tos pretty close


Attached Files
Elite Membership required to download: VariableSMA.zip
Thanked by:

 



Last Updated on October 28, 2014


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts