NexusFi: Find Your Edge


Home Menu

 





Match zerolines and scaling of two studies in same lower panel


Discussion in ThinkOrSwim

Updated
    1. trending_up 2,585 views
    2. thumb_up 1 thanks given
    3. group 1 followers
    1. forum 3 posts
    2. attach_file 1 attachments




 
Search this Thread

Match zerolines and scaling of two studies in same lower panel

  #1 (permalink)
 
Lancer's Avatar
 Lancer 
Seattle, USA
 
Experience: Intermediate
Platform: NinjaTrader / ThinkOrSwim
Broker: NinjaTrader / TDAmeritrade
Trading: Futures, Equities
Posts: 35 since Jul 2016
Thanks Given: 16
Thanks Received: 34

Using two standard TOS studies, MACDTwoLines and MACDHistogram in the same lower panel, where are the settings controls to match the zerolines and right axis scaling? As it is now, both studies have separate zero lines, and the right axis scale changed to percentage, and there is no way to change it that I can see.

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
PowerLanguage & EasyLanguage. How to get the platfor …
EasyLanguage Programming
ZombieSqueeze
Platforms and Indicators
How to apply profiles
Traders Hideout
Exit Strategy
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Just another trading journal: PA, Wyckoff & Trends
31 thanks
Spoo-nalysis ES e-mini futures S&P 500
28 thanks
Tao te Trade: way of the WLD
24 thanks
Bigger Wins or Fewer Losses?
20 thanks
GFIs1 1 DAX trade per day journal
17 thanks
  #2 (permalink)
 
Lancer's Avatar
 Lancer 
Seattle, USA
 
Experience: Intermediate
Platform: NinjaTrader / ThinkOrSwim
Broker: NinjaTrader / TDAmeritrade
Trading: Futures, Equities
Posts: 35 since Jul 2016
Thanks Given: 16
Thanks Received: 34

No answer, so I'll assume there are no controls to set multiple studies in a lower panel to the same right scale. So, does anyone have a Thinkscript file that plots both the MACDTwoLines and the MACDHistogram? In a single script, the zerolines and the vertical scale would be the same.

There are a few TOS scripts here on futures.io, but not that one exactly. Does anyone know if TDAmeritrade has an archive of Thinkscript files posted by users, available for download?

Started this thread Reply With Quote
  #3 (permalink)
 growex 
Trubchevsk
 
Experience: Beginner
Platform: tos
Trading: stocks
Posts: 61 since May 2011
Thanks Given: 40
Thanks Received: 79



Lancer View Post
No answer, so I'll assume there are no controls to set multiple studies in a lower panel to the same right scale. So, does anyone have a Thinkscript file that plots both the MACDTwoLines and the MACDHistogram? In a single script, the zerolines and the vertical scale would be the same.

There are a few TOS scripts here on futures.io, but not that one exactly. Does anyone know if TDAmeritrade has an archive of Thinkscript files posted by users, available for download?




declare lower;

input fastLength = 12;
input slowLength = 26;
input MACDLength = 9;
input averageType = AverageType.EXPONENTIAL;
plot Value = MACD(fastLength, slowLength, MACDLength, averageType).Value;
plot Avg = MACD(fastLength, slowLength, MACDLength, averageType).Avg;
plot Diff = MACD(fastLength, slowLength, MACDLength, averageType).Diff;
plot ZeroLine = 0;
Value.SetDefaultColor(GetColor(1));
Avg.SetDefaultColor(GetColor(8));
ZeroLine.SetDefaultColor(GetColor(0));
Diff.SetDefaultColor(GetColor(5));
Diff.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
Diff.SetLineWeight(3);
Diff.DefineColor("Positive and Up", Color.GREEN);
Diff.DefineColor("Positive and Down", Color.DARK_GREEN);
Diff.DefineColor("Negative and Down", Color.RED);
Diff.DefineColor("Negative and Up", Color.DARK_RED);
Diff.AssignValueColor(if Diff >= 0 then if Diff > Diff[1] then Diff.color("Positive and Up") else Diff.color("Positive and Down") else if Diff < Diff[1] then Diff.color("Negative and Down") else Diff.color("Negative and Up"));

Follow me on Twitter Reply With Quote
Thanked by:
  #4 (permalink)
 
Lancer's Avatar
 Lancer 
Seattle, USA
 
Experience: Intermediate
Platform: NinjaTrader / ThinkOrSwim
Broker: NinjaTrader / TDAmeritrade
Trading: Futures, Equities
Posts: 35 since Jul 2016
Thanks Given: 16
Thanks Received: 34

Thanks to growex. Here is the script file.

Attached Files
Elite Membership required to download: MACDandHistogramSTUDY.ts
Started this thread Reply With Quote




Last Updated on April 7, 2018


© 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