Alerts based on Hull Moving Avg direction - futures io
futures io futures trading



Alerts based on Hull Moving Avg direction


Discussion in ThinkOrSwim

Updated by arye
      Top Posters
    1. looks_one eddieo with 3 posts (0 thanks)
    2. looks_two rmejia with 2 posts (5 thanks)
    3. looks_3 drewtrade with 1 posts (0 thanks)
    4. looks_4 arye with 1 posts (0 thanks)
    1. trending_up 6,336 views
    2. thumb_up 5 thanks given
    3. group 5 followers
    1. forum 8 replies
    2. attach_file 0 attachments




Welcome to futures io: the largest futures trading community on the planet, with well over 100,000 members
  • Genuine reviews from real traders, not fake reviews from stealth vendors
  • Quality education from leading professional traders
  • We are a friendly, helpful, and positive community
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts
  • We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

(If you already have an account, login at the top of the page)

 
Search this Thread
 

Alerts based on Hull Moving Avg direction

(login for full post details)
  #1 (permalink)
New York, NY
 
 
Posts: 4 since Feb 2015
Thanks: 1 given, 0 received

Hi,
I'm interested in triggering an alert in T.O.S. when the Hull Moving Average direction switches from Up to Down or vice versa.

The standard tools within Alerts allow you to trigger based on values being met or crossed, but not on the direction of the average.

Is anyone aware of how to set this up using Thinkscript or any other means?

Thanks,

EddieO

Reply With Quote

Can you help answer these questions
from other members on futures io?
Looking freelancer for MT4 Indicator
Platforms and Indicators
OPEN_CLOSE_DOTS
ThinkOrSwim
Horizontal Line Indicator
Platforms and Indicators
IB Bracker Order
Platforms and Indicators
DLL with webrequest function for MC
MultiCharts
 
 
(login for full post details)
  #2 (permalink)
New York, NY
 
 
Posts: 4 since Feb 2015
Thanks: 1 given, 0 received

If anyone has ideas, would be much appreciated!

Reply With Quote
 
(login for full post details)
  #3 (permalink)
Puerto Rico
 
Experience: Intermediate
Platform: thinkorswim
Broker: TD Ameritrade
Trading: ES
 
rmejia's Avatar
 
Posts: 377 since Oct 2010
Thanks: 3,600 given, 432 received



eddieo View Post
If anyone has ideas, would be much appreciated!

 
Code
    
    #Hull Moving Average

input price = close;
input length = 20;
input displace = 0;

plot HMA = MovingAverage(AverageType.HULL, price, length)[-displace];

HMA.DefineColor("Up", GetColor(1));
HMA.DefineColor("Down", GetColor(0));
HMA.AssignValueColor(if HMA > HMA[1] then HMA.color("Up") else HMA.color("Down"));


    #Alert
Alert(HMA > HMA[1] and HMA[1] < HMA[2], "Up", Alert.BAR, Sound.Bell);
Alert(HMA < HMA[1] and HMA[1] > HMA[2], "Down", Alert.BAR, Sound.Bell);

Reply With Quote
The following 5 users say Thank You to rmejia for this post:
 
(login for full post details)
  #4 (permalink)
New York, NY
 
 
Posts: 4 since Feb 2015
Thanks: 1 given, 0 received

Thank you rmejia! This is fantastic.

Reply With Quote
 
(login for full post details)
  #5 (permalink)
Sioux Falls
 
 
Posts: 1 since Jan 2016
Thanks: 0 given, 0 received

Hello, thanks for this, its exactly what I'm looking for as well (if I could just get it working haha). So I've created the study and added the thinkscript, however, it doesnt seem to be working....I purely copied and pasted the code....what should the "trigger if" condition be? I'm thinking that's where my problem may lie, but still not sure. Any help getting this working would be much appreciated. Thanks!

Reply With Quote
 
(login for full post details)
  #6 (permalink)
Puerto Rico
 
Experience: Intermediate
Platform: thinkorswim
Broker: TD Ameritrade
Trading: ES
 
rmejia's Avatar
 
Posts: 377 since Oct 2010
Thanks: 3,600 given, 432 received

The trigger is a change in direction for the hull line. When it changes from up to down (color change) a sound and notification should trigger in thinkorswim.

Reply With Quote
 
(login for full post details)
  #7 (permalink)
Tilburg
 
 
Posts: 2 since Oct 2017
Thanks: 0 given, 0 received

Hi, this indicator is just what I needed!

Sorry for digging up an older post but I would like to ask for an addition.

Is it possible to add code so that there is a visual on change of direction?

Like an arrow or dot underneath or above the change of direction.

Thanks in advance!

Regards,

Patrick

Reply With Quote
 
(login for full post details)
  #8 (permalink)
Adrian
 
Experience: Master
Platform: TOS and Ninjatrader
Trading: SPY
 
Posts: 15 since Aug 2015
Thanks: 0 given, 7 received

How can I set up a scan to scan stocks that have just crossed over on a daily time period?

Reply With Quote
 
(login for full post details)
  #9 (permalink)
fort smith
 
 
Posts: 1 since Feb 2019
Thanks: 0 given, 0 received


rmejia View Post
The trigger is a change in direction for the hull line. When it changes from up to down (color change) a sound and notification should trigger in thinkorswim.


Thank you for this code. I have the same problem though on the trigger. I clicked on study alert and then copied the code in scripteditor but right beneath that is a section that says "trigger if:" and a drop down box for at, below, above, etc for a specific price. There is no way that I can see to eliminate this requirement so every time I set the alert it essentially becomes a price alert. What am I missing? thank you so much for your help.

Reply With Quote


futures io Trading Community Platforms and Indicators ThinkOrSwim > Alerts based on Hull Moving Avg direction


August 21, 2019


Upcoming Webinars and Events
     



Copyright © 2020 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
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.
no new posts