Drum Rocker
Member
I have been trying to figure out the code for this but got stuck and need help. Based on the chart below, I would love to have these times marked with vertical lines with a label. Or what might also be cool is to have a color bar at the bottom of the price chart spread over these time frames with a label for the trend potential. Whichever is easier.
For example, dashed vertical lines at 9:30 with text that says "Medium Trend". The 10:00 line would say "Very High Trend". The 11:30 would say "Low Trend". And so on. I don't need anything for Risk and Volume as noted in the chart below. I trade in Central Standard Time if that matters.
Here is the code I started but the time's not setting correctly.
Thanks for any assistance.
For example, dashed vertical lines at 9:30 with text that says "Medium Trend". The 10:00 line would say "Very High Trend". The 11:30 would say "Low Trend". And so on. I don't need anything for Risk and Volume as noted in the chart below. I trade in Central Standard Time if that matters.
Here is the code I started but the time's not setting correctly.
Thanks for any assistance.
Code:
#
input targetTime830 = 830;
def targetBar830 = SecondsFromTime(targetTime830) == 0;
input targetTime1000 = 1000;
def targetBar1000 = SecondsFromTime(targetTime1000) == 0;
AddVerticalLine(targetBar1000, "VERY HIGH TREND TIME", Color.GREEN);
input targetTime1430 = 1430;
def targetBar1430 = SecondsFromTime(targetTime1430) == 0;
AddVerticalLine(targetBar1430, "HIGH TREND TIME", Color.WHITE);
Code:
Last edited by a moderator: