Hi Pete, can you please take a look at the code below that is made to track the current days high. It works fine on a computer but when I transfer it to mobile instead of tracking the current high of day, it moves to the bars high of day. Thanks.
def MktPlot = GetLastDay() – 8 <= GetDay() and GetLastYear() – 0 <= GetYear();
def RMplots = RegularTradingStart (GetYYYYMMDD()) > GetTime() – 28880000;
def day = GetDay();
def Open = day != day;
def CDHigh = if !day then Double.NaN else high (period = “day”);
plot CDH = if MktPlot and RMplots then CDHigh else Double.NaN;
Marked as spam
*The bars high, not high of day. So essentially on mobile, it justs draws a line from each bars high to the next high.
Secondary aggregation periods are not currently supported on the mobile platform. I have not found a way to work around this limitation.
Edit: After reviewing the comment to my original answer I decided to test one of the indicators published on the Hahn-Tech website. I found the chart study included with the following video does indeed work on the mobile app. Previously this chart study was not supported on the mobile app. TDA developers must have added support for this sort of solution in a recent upgrade.
Thinkorswim Alert High Low Version 2 https://www.hahn-tech.com/thinkorswim-alert-high-low-version-two/
Marked as spam
They were talking about a workaround for something similar at https://usethinkscript.com/threads/fix-secondary-period-not-allowed-in-thinkorswim-scanner.927/ I tried to use this and I got close, but I never figured out how to properly use it. Could you take a look and see if it applies to my situation? Thanks.
I updated my answer to include a solution. I did not find any useable solution in the link you provided. But I only viewed the first page in that thread. I decided it would be quicker for me to simply test one of the indicators I have already published.
Ok thanks! Is it possible to change your script so it plots previous day highs and lows instead of current day highs and lows?
Not really, no. The code was only intended to track current day's high and low.
Please log in to post questions.