NexusFi: Find Your Edge

Home Menu


Stochastics Color Changing

Discussion in EasyLanguage Programming

      Top Posters
    1. looks_one wbtrader with 2 posts (0 thanks)
    2. looks_two Serger with 1 posts (1 thanks)
    3. looks_3 Big Mike with 1 posts (0 thanks)
    4. looks_4 RM99 with 1 posts (1 thanks)
    1. trending_up 4,223 views
    2. thumb_up 2 thanks given
    3. group 3 followers
    1. forum 4 posts
    2. attach_file 1 attachments

Search this Thread
  #1 (permalink)
atlanta ga usa
Experience: Advanced
Platform: tradestation, ninja trader
Trading: es
Posts: 12 since Aug 2011
Thanks Given: 10
Thanks Received: 5

does anyone have a stochastics that changes color when overbought and oversold? i have this for ninja but cant seem to find it for tradestation. i would greatly appreciate it! thanks

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Zombie Indicator Help
Bare bones, how the EUR/USD contract move?
Traders Hideout
NexusFi Journal Challenge - June 2024
Feedback and Announcements
Help re translation of ninjascript to EL
CosMik Z-TP Trading System
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Vinny E-Mini & Algobox Review TRADE ROOM
83 thanks
GFIs1 1 DAX trade per day journal
45 thanks
Risk/reward above 1.0
21 thanks
What Do You Replace Positive Thing With
18 thanks
Big Mike in Ecuador
14 thanks
  #2 (permalink)
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Swing Trader
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,530 since Jun 2009
Thanks Given: 33,278
Thanks Received: 101,766

Thread Moved

Moved to EasyLanguage Programming

When creating a new thread, note which subforum you are in. Here is a short list of suggestions:

- Topic: Anything to do with an Elite indicator -> Subforum: The Elite Circle
- Topic: Looking for an existing indicator, or how-to use an indicator -> Subforum: (the platform)
- Topic: Programmer needing help with non-Elite indicator -> Subforum: (the platform) - Programming
- Topic: Want an indicator created/modified -> Reply to "Want indicator created free" in Elite Circle
- Topic: Vendors (trading rooms, commercial indicators) -> Subforum: Vendors/Product Reviews
- Topic: Discussion of Forex or Currency trading -> Subforum: Forex and Currency Trading
- Topic: Journals of your trading -> Subforum: Trading Journals or Elite Trading Journals
- Topic: General trading related discussions -> Subforum: Traders Hideout
- Topic: Discussion of a trading method -> Subforum: Traders Hideout
- Topic: Automated Trading -> Subforum: Elite Automated Trading

Last, any Elite Member may create more or less any of these topics in The Elite Circle at your own discretion (your support is appreciated).

This is just a short general list and doesn't cover everything. If you are unsure where to create your new thread, just create it in Traders Hideout and a moderator will move it if necessary.

-- Big Mike Trading

Join the free Markets Chat beta: Real-time Trading Insights

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 Reply With Quote
  #3 (permalink)
Austin, TX
Experience: Advanced
Platform: TradeStation
Trading: Futures
Posts: 839 since Mar 2011
Thanks Given: 124
Thanks Received: 704

Try this, you can mess around with the color settings to your liking. You'll need the stochastic function that's embedded.
 PriceH( High ),  
 PriceL( Low ), 
 PriceC( Close ), 
 StochLength( 14 ), 
 SmoothingLength1( 3 ), { used to slow FastK to FastD = SlowK }
 SmoothingLength2( 3 ), { used to slow FastD to SlowD }
 SmoothingType( 1 ), { pass in 1 for Original, 2 for Legacy }
 OverSold( 20 ), 
 OverBought( 80 ) ,
 OverSColor( Cyan ), 
 OverBColor( Red ) ;
 oFastK( 0 ), 
 oFastD( 0 ), 
 oSlowK( 0 ), 
 oSlowD( 0 ) ;
Value1 = Stochastic( PriceH, PriceL, PriceC, StochLength, SmoothingLength1, 
 SmoothingLength2, SmoothingType, oFastK, oFastD, oSlowK, oSlowD ) ;
Plot1( oFastK, "FastK", blue ) ;
Plot2( oFastD, "FastD", yellow) ;
Plot3( OverBought, "OverBot" ) ;
Plot4( OverSold, "OverSld" ) ;
{ Color criteria }
if oFastK > OverBought then 
 SetPlotColor( 1, OverBColor ) 
else if oFastK < OverSold then 
 SetPlotColor( 1, OverSColor ) ;
if oFastD > OverBought then 
 SetPlotColor( 1, OverBColor ) 
else if oFastD < OverSold then 
 SetPlotColor( 1, OverSColor ) ;
{ Alert criteria }
if oFastD crosses over OverSold then
 Alert( "FastD exiting oversold zone" )
else if oFastD crosses under OverBought then
 Alert( "FastD exiting overbought zone" ) ;

"A dumb man never learns. A smart man learns from his own failure and success. But a wise man learns from the failure and success of others."
Reply With Quote
Thanked by:
  #4 (permalink)
Serger's Avatar
Experience: Intermediate
Platform: Multicharts 64 +VolProfile
Broker: Interactive Brokers
Trading: Ym, Es
Posts: 74 since Oct 2010
Thanks Given: 64
Thanks Received: 25

this work well
Price( Close ),
Length( 14 ),
OverSold( 30 ),
OverBought( 70 ),
OverSColor( Cyan ),
OverBColor( Red ) ;

variables: var0( 0 ) ;

var0 = RSI( Price, Length ) ;

Plot1( var0, "RSI" ) ;
Plot2( OverBought, "OverBot" ) ;
Plot3( OverSold, "OverSld" ) ;

if var0 > OverBought then
SetPlotColor( 1, OverBColor )
else if var0 < OverSold then
SetPlotColor( 1, OverSColor ) ;

condition1 = var0 crosses over OverSold ;
if condition1 then
Alert( "Indicator exiting oversold zone" )
condition1 = var0 crosses under OverBought ;
if condition1 then
Alert( "Indicator exiting overbought zone" ) ;

Reply With Quote
Thanked by:
  #5 (permalink)
atlanta ga usa
Experience: Advanced
Platform: tradestation, ninja trader
Trading: es
Posts: 12 since Aug 2011
Thanks Given: 10
Thanks Received: 5

thanks guys for the help. unfortunately i couldnt seem to make the codes work. i got the first one to apply color changes to the indicator but there seemed to be some settings i was missing. it was very messy. if you have any guidance it is greatly appreciated. I have attached a pic of the current one im using on ninja. thanks!

Attached Thumbnails
Click image for larger version

Name:	Color Change.JPG
Views:	271
Size:	36.2 KB
ID:	47668  
Started this thread Reply With Quote

Last Updated on August 29, 2011

© 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