NexusFi: Find Your Edge


Home Menu

 





PlotColors as strategy trigger


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one microsat with 2 posts (0 thanks)
    2. looks_two cory with 2 posts (2 thanks)
    3. looks_3 Quick Summary with 1 posts (0 thanks)
    4. looks_4 Riverend with 1 posts (0 thanks)
    1. trending_up 1,601 views
    2. thumb_up 3 thanks given
    3. group 4 followers
    1. forum 7 posts
    2. attach_file 2 attachments




 
Search this Thread

PlotColors as strategy trigger

  #1 (permalink)
microsat
houston texas/us
 
Posts: 25 since Dec 2014
Thanks Given: 6
Thanks Received: 2

Can we use PlotColors as strategy trigger?

like
if (CustomIndicator.PlotColors[0][0]==Color.Red)
EnterShort();

Reply With Quote

Can you help answer these questions
from other members on NexusFi?
ZombieSqueeze
Platforms and Indicators
How to apply profiles
Traders Hideout
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
MC PL editor upgrade
MultiCharts
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
What is Markets Chat (markets.chat) real-time trading ro …
80 thanks
Spoo-nalysis ES e-mini futures S&P 500
55 thanks
Tao te Trade: way of the WLD
46 thanks
Just another trading journal: PA, Wyckoff & Trends
35 thanks
The Program
19 thanks
  #3 (permalink)
 
cory's Avatar
 cory 
virginia
 
Experience: Intermediate
Platform: ninja
Trading: NQ
Posts: 6,098 since Jun 2009
Thanks Given: 877
Thanks Received: 8,090



microsat View Post
Can we use PlotColors as strategy trigger?

like
if (CustomIndicator.PlotColors[0][0]==Color.Red)
EnterShort();

maybe it's better to understand which condition to make it red.

Reply With Quote
Thanked by:
  #4 (permalink)
microsat
houston texas/us
 
Posts: 25 since Dec 2014
Thanks Given: 6
Thanks Received: 2

in the indicator,
if (Rising(SMA(14)) && RSI(14) > 30 )
PlotColors[0][0] = RisingColor; //Color.Blue
else if (Falling(SMA(14)) && RSI(14) < 70 )
PlotColors[0][0] = FallingColor; //Color.Red
else
PlotColors[0][0] = NeutralColor; //Color.Yellow


Can we just use PlotColors[0][0] to trigger the short/long entry in a strategy?

When I tried to call PlotColors[0][0], it always gave back 'Color [Empty]'.
But in chart mode of the backtest, the indicator does show three different colors.


cory View Post
maybe it's better to understand which condition to make it red.


Reply With Quote
  #5 (permalink)
 Jaba 
Austin TX
 
Experience: Intermediate
Platform: SaintGobain Crystal Ball
Trading: NQ
Posts: 81 since Oct 2010
Thanks Given: 103
Thanks Received: 134


cory View Post
maybe it's better to understand which condition to make it red.

Well, bulls charge when they see red, right? Then what bears do? They don't like green... I'm confused

Reply With Quote
  #6 (permalink)
 
Riverend's Avatar
 Riverend 
Westlake, Oh
 
Experience: Beginner
Platform: NinjaTrader
Trading: CL
Posts: 356 since Jun 2009
Thanks Given: 1,519
Thanks Received: 220

@cory
I tried using this indicator with the strategy wizard but the two colors green or red are not available when I select
"plot" in the Wizard Gui. When I edited the indicator I see plots for red and green also Rising and falling is referenced.Can the
colors or directions be added to the Strategy Wizard. BTW some funny comments by @Zondor the script. Any help would be appreciated.



LowPassFilter_v1(1).zip


Reply With Quote
  #7 (permalink)
 
cory's Avatar
 cory 
virginia
 
Experience: Intermediate
Platform: ninja
Trading: NQ
Posts: 6,098 since Jun 2009
Thanks Given: 877
Thanks Received: 8,090


Riverend View Post
...
I tried using this indicator with the strategy...

I don't know how to use strategy, sorry!

Reply With Quote
Thanked by:
  #8 (permalink)
 
DavidHP's Avatar
 DavidHP 
Isla Mujeres, MX
Legendary Market Wizard
 
Experience: Advanced
Platform: NinjaTrader
Broker: Ninjatrader / Optimus Futures / AmpFutures
Trading: ES / 6E / 6B / CL
Frequency: Every few days
Duration: Minutes
Posts: 1,612 since Aug 2009
Thanks Given: 11,341
Thanks Received: 2,747


microsat View Post
in the indicator,
if (Rising(SMA(14)) && RSI(14) > 30 )
PlotColors[0][0] = RisingColor; //Color.Blue
else if (Falling(SMA(14)) && RSI(14) < 70 )
PlotColors[0][0] = FallingColor; //Color.Red
else
PlotColors[0][0] = NeutralColor; //Color.Yellow


Can we just use PlotColors[0][0] to trigger the short/long entry in a strategy?

When I tried to call PlotColors[0][0], it always gave back 'Color [Empty]'.
But in chart mode of the backtest, the indicator does show three different colors.

@microsat I've done this in one of my indicators or strategy but I'm not on my main PC to copy and paste it.
I will look it up this weekend if you are still interested.
Let me know if I should search for it.

Rejoice in the Thunderstorms of Life . . .
Knowing it's not about Clouds or Wind. . .
But Learning to Dance in the Rain ! ! !
Follow me on Twitter Reply With Quote
Thanked by:




Last Updated on September 18, 2015


© 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