I'm trying to get current value of upper and lower bollinger band and get the distance between them.

To add comments, please log in or register
Ahmed Butt
16
Ahmed Butt  
I'm trying to make an indicator which alert when the bollinger band squeeze at the define distance and alert when the bands start open . I'm new to mql4 , Could someone help ?
Mark Wilson
879
Mark Wilson  
Ahmed Butt:
I'm trying to make an indicator which alert when the bollinger band squeeze at the define distance and alert when the bands start open . I'm new to mql4 , Could someone help ?

If your new to MQL it can be helpful to take an existing indicator and adjust it so that it displays what you want.   Perhaps take something like the RSI indicator, copy the code and adjust it so that it displays the Bollinger band squeeze.   This function might be useful: iBands.   You could then try to adjust it to include some extra reporting like SendMail, SendNotification, Comment, Print, Alert.   If you don't need to see the squeeze and just want an email, you could stick it in an EA rather than an indicator.   It would also be a good idea to think about when you want the alert to happen.   For example it wouldn't be great if you had an Alert box firing off every time you get a tick outside of the Bollinger Band squeeze.   You could take a look at the common functions list Common Functions, and you may want to know how to manipulate date and time

SendMail - Common Functions - MQL4 Reference
SendMail - Common Functions - MQL4 Reference
  • docs.mql4.com
SendMail - Common Functions - MQL4 Reference
Ahmed Butt
16
Ahmed Butt  
Mark Wilson:

If your new to MQL it can be helpful to take an existing indicator and adjust it so that it displays what you want.   Perhaps take something like the RSI indicator, copy the code and adjust it so that it displays the Bollinger band squeeze.   This function might be useful: iBands.   You could then try to adjust it to include some extra reporting like SendMail, SendNotification, Comment, Print, Alert.   If you don't need to see the squeeze and just want an email, you could stick it in an EA rather than an indicator.   It would also be a good idea to think about when you want the alert to happen.   For example it wouldn't be great if you had an Alert box firing off every time you get a tick outside of the Bollinger Band squeeze.   You could take a look at the common functions list Common Functions, and you may want to know how to manipulate date and time

Okay thanks very much. I've found the values of upper and lower band . I'll come back to you If I stuck somewhere. Thanks again.

   

mntiwana
4237
mntiwana  

Hi Ahmed

There are a lot of types and styles of BB,almost of every sort,you needs to explain more in details and or describe with demonstrating picture/s so that some one can help you in right direction

1
Ahmed Butt
16
Ahmed Butt  

Hi,

Can I get Bollinger band squeeze and expansion code .

If not so can anybody tell to get parameters value set in bollinger bands like deviation , bands_shift etc .

Short Squeeze - Imbalance of Supply and Demand - Tradingsim
Short Squeeze - Imbalance of Supply and Demand - Tradingsim
  • tradingsim.com
A short squeeze is a direct result of the lack of supply and demand in a security. The resulting affect of the squeeze is a sharp rally in the price of the security. What Causes a Short Squeeze Short squeezes can occur on any trading timeframe. However, the most powerful short squeezes occur after a security has been in an extended downtrend...
To add comments, please log in or register