NinjaTrader Support Forum  

Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Strategy Development

Strategy Development Support for the development of custom automated trading strategies using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 08-13-2009, 06:03 PM   #1
devaji
Junior Member
 
Join Date: Aug 2009
Posts: 3
Thanks: 0
Thanked 0 times in 0 posts
Default Uptrend/Downtrend Colors on Bar Chart

I am new to ninja script. I am looking to create an uptrend/downtrend indicator (using MACD as the basis) that turns the bars to green in an uptrend and to red in a downtrend. I am sure it is very simple for those who are expert at programming, which I am inept. I would appreciate any help. Thanks.


If MACD (Standard settings) is greater than 0 and the MACD Diff (Histogram) is greater than 0, then the bars (on the chart) turn green.

Otherwise -

If MACD (Standard settings) is less than 0 and the MACD Diff (Histogram) is less than 0, then the bars (on the chart) turn red.
devaji is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Special Bar Colors if Close on High or Low Turtle21 Indicator Development 4 07-30-2009 03:52 PM
reading bar colors? Burga1 Strategy Development 15 05-18-2008 10:49 PM
reference past bar colors? Burga1 General Programming 4 04-24-2008 06:45 PM
bar colors pgabriel Charting 1 11-29-2007 11:12 AM
Custom Plot colors & Thresholds & Price marker colors higler General Programming 5 06-22-2007 07:47 AM


All times are GMT -6. The time now is 12:03 AM.