TTM Trend


0
0

Hi Hanh, using your TTM Trend sound alert as https://www.hahn-tech.com/thinkorswim-alert-ttm-trend/

will not make the price bars being painted red blue, even though i have changed your line 4

from DEF upTrend = TTM_Trend(compBars, paintBars).TrendUp;

change to PLOT upTrend = TTM_Trend(compBars, paintBars).TrendUp;

(i only want the BLUE paint, not blue and red)

Does it mean we need to load TTM Trend study as well in the chart ?

do you have idea how to make the price bars being painted blue only (not blue and red) ?

thanks a million for all your kind help.

Marked as spam
Posted by (Questions: 2, Answers: 4)
Asked on July 10, 2017 10:23 am
739 views
0
Private answer

The code provided with that video was strictly about Alerts and was never designed to change the bar color. Here is some code that should do the trick, however I have not tested it.

input compBars = 6;
input paintBars = yes;
def upTrend = TTM_Trend(compBars, paintBars).TrendUp;
AssignPriceColor(if upTrend then Color.BLUE else Color.CURRENT);

Marked as spam
Posted by (Questions: 37, Answers: 4118)
Answered on July 10, 2017 1:53 pm