shabz Posted August 7, 2010 Report Share Posted August 7, 2010 (edited) Is it possible to create an indicator that uses 2 other indicator's conditions to alert 1 of 4 possible conditions on a chart ? The indicators I have in mind are the Osma and the Hull moving average. I would like to have Strong BUY, Weak BUY, Strong SELL & Weak SELL printed as 4 types of arrows with alert with the 4 conditions are met. A simple strategy made simpler by a visual signal. Edited August 7, 2010 by shabz wording Quote Link to comment Share on other sites More sharing options...
Guest Todayke Posted August 7, 2010 Report Share Posted August 7, 2010 Yes, it is possible. Write down the rules! Quote Link to comment Share on other sites More sharing options...
chrisbenjy Posted August 7, 2010 Report Share Posted August 7, 2010 yes, on "MetaEditor" along the bottom on the debug menu it says "help". Click on it and then scroll down and on the left hand side click "Technical indicators". Then scroll down again and click "iCustom". Then read that page. It should help you with your query, but if you get stuck just post another question on here. Chris Quote Link to comment Share on other sites More sharing options...
shabz Posted August 8, 2010 Author Report Share Posted August 8, 2010 (edited) Simple Rules: Price bar must close for each condition. Above both 10 Sma & 40 Hma = Buy . Below both 10 Sma & 40 Hma = Sell. (Must have adjustable parameters) Filter for Strength is the Osma. (again parameters adjustable). Above 0 level & Rising = Strong Buy, Above & Falling = Weak Buy Below 0 level & Falling = Strong Sell, Below & rising = Weak Sell I will attach the indicators that I am using. The SMa is the standard one with MT4 Indicators attached below Edited August 8, 2010 by shabz Quote Link to comment Share on other sites More sharing options...
shabz Posted August 8, 2010 Author Report Share Posted August 8, 2010 These are the indicator files: http://www.4shared.com/file/qQbOtuM_/HMA_40_slow.html http://www.4shared.com/file/h1FY0743/MACD_OsMA_4ColorH_2LVar_mtf.html Quote Link to comment Share on other sites More sharing options...
iwjw Posted August 8, 2010 Report Share Posted August 8, 2010 Is it possible to create an indicator that uses 2 other indicator's conditions to alert 1 of 4 possible conditions on a chart ? The indicators I have in mind are the Osma and the Hull moving average. I would like to have Strong BUY, Weak BUY, Strong SELL & Weak SELL printed as 4 types of arrows with alert with the 4 conditions are met. A simple strategy made simpler by a visual signal. Didn't test it properly but maybe it's useful for you: http://[email protected]/file/MDTod9Vl/_shabz.html Quote Link to comment Share on other sites More sharing options...
shabz Posted August 8, 2010 Author Report Share Posted August 8, 2010 Hi iwjw, Indicator looks fine the way it is set up, I am finding the arrows are not lining up quite as well to the conditions - some are late, some are totally missing. Maybe the attached screenshot might help. http://www.4shared.com/photo/g3T_vjmq/04_Aug_08_1500.html Quote Link to comment Share on other sites More sharing options...
iwjw Posted August 8, 2010 Report Share Posted August 8, 2010 (edited) Hi iwjw, Indicator looks fine the way it is set up, I am finding the arrows are not lining up quite as well to the conditions - some are late, some are totally missing. Maybe the attached screenshot might help. http://www.4shared.com/photo/g3T_vjmq/04_Aug_08_1500.html The missing of signals might have something to do with my display filter (where the alert is generated) to show a signal only once If same type of signal occurs consecutive the indi will not show the second signal I guess For signal being late, the arrow occurs on that candle that would be the opening candle for the trade. So the conditions were met one candle prior But the code is really simple so it shouldn't be that hard to fix it btw. the indi is looking good on a renko chart EDIT: just saw it...I'm using the signal line of the OsMA and not the histogram Edited August 8, 2010 by iwjw Quote Link to comment Share on other sites More sharing options...
Guest raw Posted August 8, 2010 Report Share Posted August 8, 2010 These are the indicator files: http://www.4shared.com/file/qQbOtuM_/HMA_40_slow.html http://www.4shared.com/file/h1FY0743/MACD_OsMA_4ColorH_2LVar_mtf.html Could you please Upload again? Second file not available. Thx. Raw Quote Link to comment Share on other sites More sharing options...
shabz Posted August 8, 2010 Author Report Share Posted August 8, 2010 Hi iwjw, Can you have the signal firing on the close of the candle where the condition is met, rather than the open of the next candle ? The filter is the Osma histogram, you can take off 2 lines of Macd, by setting them to none. Also was I correct with the colours of the arrows for Strong & Weak ? Quote Link to comment Share on other sites More sharing options...
iwjw Posted August 8, 2010 Report Share Posted August 8, 2010 Hi iwjw, Can you have the signal firing on the close of the candle where the condition is met, rather than the open of the next candle ? The filter is the Osma histogram, you can take off 2 lines of Macd, by setting them to none. Also was I correct with the colours of the arrows for Strong & Weak ? I've changed the arrow position, but for me the indi would be a repainter now Fixed a bug in alert functionality....the bug is still in the first version Changed to OsMA histogram Don't know whether the implementation is correct now, but for me the indi would be unusable now because of the tons of signals I'll play around with the signal line version a little bit and leave the _2 version as it is http://[email protected]/file/4DFUfSh8/_shabz_2.html shabz 1 Quote Link to comment Share on other sites More sharing options...
shabz Posted August 8, 2010 Author Report Share Posted August 8, 2010 (edited) Hi iwjw, The Macd indicator is mtf, when I set it to 15 TF on a 5 min TF, the Osma histogram is OK for the SELL side, but on the BUY side (dark blue bars) there are errors I'm sure. Need to check if there is a coding error there ? It will definitely improve the signal I am sure, if we can correct the indicator errors. I don't mind all the extra signals, it only confirms the direction of trend. You can always filter them in terms of strength. But fixing the macd might help. Edited August 8, 2010 by shabz Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.