Automatically Recreate Study Alerts


0
0

Hi Pete,

Apologies for asking a question that has already been asked but I could not follow your reply.

Someone else has encountered my same issue. I programmed a strategy and then I programmed a study based on that strategy so that I can be alerted when certain conditions are met. The issue is how to get the alerts been recursive (so that I do not have to re-set the alert every time it is triggered).

You have already replied to this question but I was not able to understand.

In particular, I attach a screenshot of what I see when I clink on “Study Alerts” in “MarketWatch” (“Alerts”).

I also attach your screenshot. The question is: where did you click to open that window?

Thanks a lot in advance and apologies again for double asking.

R.

Attachments:
Marked as spam
Posted by (Questions: 7, Answers: 6)
Asked on December 13, 2016 4:44 am
2313 views
0

The original title to this question has been changed from ”Recursive Alerts” to ”Automatically Recreate Study Alerts”. The word Recursive, in the context of Study Alerts most often refers to a variable who’s current value is based on a previous value. For Study Alerts, these kinds of statements are not supported and will create an error.

( at December 13, 2016 8:33 am)
2
Private answer

I’m going to change the title of your question to “Automatically Recreate Study Alerts”. The term “Recursive” has a very specific meaning in the context of study alerts and I don’t want folks to get confused.

You may think this question has already been asked but there is a subtle difference between the screen you provided and the second one. The second one is from a Price based alert. To access the settings you on the Study Alert, simply click the button in the bottom left labeled “+ Set Alert Rules..”.

I know, why on earth wouldn’t they make these two screens match. The choices are slightly different. There are two checkboxes. Mark the one labeled “Recreate alert for reverse crossover”.

Hope it helps. Please be sure to up-vote the question the provides the best solution!

Marked as spam
Posted by (Questions: 37, Answers: 4117)
Answered on December 13, 2016 8:27 am
0
Private answer

This was your screenshot I was talking about.

Attachments:
Marked as spam
Posted by (Questions: 7, Answers: 6)
Answered on December 13, 2016 4:45 am
0
Private answer

Pete,

You are GREAT! Many many thanks!

No way I was going to figure this out on my own. Thanks again!

R.

Marked as spam
Posted by (Questions: 7, Answers: 6)
Answered on December 13, 2016 8:35 am
0
Private answer

I found the answer and have tested it this morning.  Write a nested if condition statement that tests for condition1 and set value to 1 (true), test for condition2 and set value to 0 (false) and anything else set value to 3 (forces it to not trigger).  Then set up a reverse normal alert and it will automatically alternate back and forth!

Marked as spam
Posted by (Questions: 0, Answers: 1)
Answered on March 1, 2017 9:41 am
0

I am new to thinkscript and I tried my best to implement your solution without luck. This was my simple original study:

plot Data = close;
def insideBar = if
(high[0] < high[1] && low[0] > low[1])
then
yes else no;
input price = close;

I modified it to what’s shown below:

plot Data = close;
def insideBar;
if (high[0] < high[1] && low[0] > low[1])
then
{insideBar = 1;}
else if
(high[0] > high[1] or high[0] < high[1] or high[0] == high[1]) then {insideBar = 0;} else {insideBar = 3;} input price = close; I wasn't sure what to list under condition 2 so I added a condition that's always met. Any help is greatly appreciated.

( at July 12, 2017 8:24 pm)
0

Sorry but I have no idea what you are trying to accomplish using this code. It does not appear to fit the context of this post. This post does not discuss specifics of any code, it merely discusses how to configure study alerts so they automatically regenerate after being triggered.
Since your code seems to try to define an inside bar, I can give you links to a post on that topic:

https://www.hahn-tech.com/ans/inside-days-entry-prices-on-chart/

If this does not answer your question then please create a new post, clearly explaining what you are trying to accomplish.

( at July 13, 2017 8:02 am)
0

Sorry but I have no idea what you are trying to accomplish using this code. It does not appear to fit the context of this post. This post does not discuss specifics of any code, it merely discusses how to configure study alerts so they automatically regenerate after being triggered.
Since your code seems to try to define an inside bar, I can give you links to a post on that topic:

https://www.hahn-tech.com/ans/inside-days-entry-prices-on-chart/

If this does not answer your question then please create a new post, clearly explaining what you are trying to accomplish.

( at July 13, 2017 8:03 am)