• Home
  • Forums
  • Trades
  • News
  • Calendar
  • Market
  • Brokers
  • Login
  • Join
  • User/Email: Password:
  • 6:30am
Menu
  • Forums
  • Trades
  • News
  • Calendar
  • Market
  • Brokers
  • Login
  • Join
  • 6:30am
Sister Sites
  • Metals Mine
  • Energy EXCH
  • Crypto Craft

Options

Bookmark Thread

First Page First Unread Last Page Last Post

Print Thread

Similar Threads

NonLag inverse fisher transform of RSX 62 replies

Inverse Fisher Transform Stochastic Oscillator - IFT 2 replies

Not Smoothed RSI on MT4 4 replies

Please help with Inverse Fisher Transform! IFISH! 0 replies

Inverse Fisher Transform into Excel 0 replies

  • Platform Tech
  • /
  • Reply to Thread
  • Subscribe
  • 22
Attachments: Mt4 code for smoothed inverse fisher transform of RSI
Exit Attachments
Tags: Mt4 code for smoothed inverse fisher transform of RSI
Cancel

Mt4 code for smoothed inverse fisher transform of RSI

  • Last Post
  •  
  • Page 1 2
  • Page 1 2
  •  
  • Post #1
  • Quote
  • First Post: Jun 10, 2011 10:48am Jun 10, 2011 10:48am
  •  kkeskar92
  • | Joined Sep 2010 | Status: Member | 64 Posts
This is the recent indicator based on rainbow WMA of RSI and then applying Fisher transform and it was published in 2010.

Here is the code for various platforms.

http://www.traders.com/Documentation...sTips.html#TT9

Here is the unsmoothed version of same indicator.

It would be nice if somebody codes for mt4.
Attached File(s)
File Type: mq4 Inverse Fisher Transform of RSIm.mq4   6 KB | 3,349 downloads
File Type: ex4 Inverse Fisher Transform of RSIm.ex4   5 KB | 1,656 downloads
  • Post #2
  • Quote
  • Edited 9:25pm Jun 10, 2011 4:02pm | Edited 9:25pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting kkeskar92
Disliked
It would be nice if somebody codes for mt4.
Ignored
O.K.

Quoting kkeskar92
Disliked
This is the recent indicator based on rainbow WMA of RSI and then applying Fisher transform...
Ignored
edit: if i understood it right, the rsi is not smoothed with rainbow. price is smoothed with rainbow, rsi is calculated from that result and then smoothed again with zerolag ema.. finally i-fish is applied. please let me know if it's ok, thanks.

edit2: posted a piece of crap before, if anybody downloaded it, attached is a fixed version.
Attached Image(s) (click to enlarge)
Click to Enlarge

Name: cms-vttrader.gif
Size: 121 KB
Click to Enlarge

Name: mt4.gif
Size: 23 KB
Attached File(s)
File Type: mq4 Smoothed RSI Inverse Fisher Transform.mq4   5 KB | 2,565 downloads
MarginTrader All Time Return: -2.4%
 
 
  • Post #3
  • Quote
  • Jun 10, 2011 10:50pm Jun 10, 2011 10:50pm
  •  kkeskar92
  • | Joined Sep 2010 | Status: Member | 64 Posts
Thanks Maryjane....are you using it?
The recommended settings are RSI of 5 and WMA of 9....I am using it as RSI of 10.

Here is a pic of smooth and unsmooth version....
Attached Image (click to enlarge)
Click to Enlarge

Name: rsifisher.gif
Size: 22 KB
 
 
  • Post #4
  • Quote
  • Edited Jun 11, 2011 2:09am Jun 10, 2011 11:24pm | Edited Jun 11, 2011 2:09am
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting kkeskar92
Disliked
Thanks Maryjane....are you using it?
The recommended settings are RSI of 5 and WMA of 9...
Ignored
no i'm not.. i coded it just to see if i'm able to code an indicator. i'm playing with EAs a little bit, i hate indicator code but hey, now i have a slight clue how buffers work at least I don't like these smoothed and binary-emphasized indicators.. i can't draw trendlines on them trading is all about noise and i prefer noisy indicators.

rsi(5) and wma(9) is default for Ehlers' original rsi i-fish which is:
price -> rsi(5) -> lwma(9) smooth -> i-fish.
Your rectangle-shaped plot on this one is not the output of it. It's some addition by the maker of the mod you're using.

But Vervoort's formula is quite different:
price -> ten nested and subsequently re-weighted lwma(2) smooth -> rsi(4) -> zerolag-ema(4) smooth -> i-fish.

rsi(4) and ema(4) defaults are everywhere in the codes for other platforms. Vervoort suggests trading his indy with these settings along with ARSI and stoch but these may apply to daily stock charts as usual with these guys.. and even after ten minutes of intensive googling, I was unable to find the full article from the S&C magazine. I found out it's been mq4 coded for elite section over at tsd but couldn't find a leaked copy as well.

Good luck with it. Seems to be a secret weapon

edit: yep i guessed it: http://swingtradingdaily.com/2010/12...cing%E2%80%A6/. and found Vervoort's blog, he trades daily eurusd and s&p500 with this one and bunch of other indicators.
MarginTrader All Time Return: -2.4%
 
 
  • Post #5
  • Quote
  • Jun 11, 2011 10:20am Jun 11, 2011 10:20am
  •  kkeskar92
  • | Joined Sep 2010 | Status: Member | 64 Posts
Good info...Maryjane....I am trying to use it with Heiken ashi T3 step MA to enter along the trend direction .
 
 
  • Post #6
  • Quote
  • Jun 11, 2011 12:20pm Jun 11, 2011 12:20pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
Very nice indicator, MJ.

No need to do the "false","true" thing when using arrays as Series - ArrayResize always adds a new slot to the "right " end so setting the array as series at init() time and then resizing to Bars with each new bar will do the job.

Ain't MQL4 fun?
Old Benjamin was right
 
 
  • Post #7
  • Quote
  • Jun 11, 2011 3:25pm Jun 11, 2011 3:25pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
I found this a while back when I was first learning MOL4:

http://www.forexfactory.com/showthre...ng#post2878455

Best,
Lou G
Old Benjamin was right
 
 
  • Post #8
  • Quote
  • Jun 11, 2011 3:28pm Jun 11, 2011 3:28pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting Lou G
Disliked
I found this a while back when I was first learning MOL4:

http://www.forexfactory.com/showthre...ng#post2878455

Best,
Lou G
Ignored
great stuff, thanks a lot
MarginTrader All Time Return: -2.4%
 
 
  • Post #9
  • Quote
  • Edited 4:46pm Jun 11, 2011 3:42pm | Edited 4:46pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
For others who may be following this discussion - it's kinda quick and dirty but it works...

edit: try this with 10 for the rsi, 5 for the lwma. Works well for what I'm doing.

edit: added better levels to indicator
Attached File(s)
File Type: mq4 Smoothed_RSI_EhlersIFT.mq4   2 KB | 1,954 downloads
Old Benjamin was right
 
 
  • Post #10
  • Quote
  • Jun 11, 2011 3:47pm Jun 11, 2011 3:47pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
Quoting MaryJane
Disliked
yeah i've got it first likely this way, then posted it (markets just stopped), then loaded into visual tester - grrrr, repainted like hell! that false/true bloops worked for me, i've found this and was in such an euphoria it started to draw correctly that i didn't try anything anymore just posted this one that works. But it was probably another mistake - my first indy. I'll try it, thanks!

edit: tried it, can't get rid of repainting...
Ignored
Looking at the code - I can't see how it can repaint...
Old Benjamin was right
 
 
  • Post #11
  • Quote
  • Jun 11, 2011 4:01pm Jun 11, 2011 4:01pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
not repainting in usual sense.. but i have tried to set the arrays as series in init() then resize them to Bars on a new bar and they messed up.. so it looked like repainting.. but i guess i should shift them somehow at some point I'll go through the link you posted, still have to grasp the basics fully. i have a little problem with the reverse direction of indexing, thinking this way makes me feel like having to walk backwards ..i'll get it with time. Many thanks for the input. I remember your work on ALF when i was lurking around a year ago
MarginTrader All Time Return: -2.4%
 
 
  • Post #12
  • Quote
  • Jun 11, 2011 4:07pm Jun 11, 2011 4:07pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
Quoting MaryJane
Disliked
I remember your work on ALF when i was lurking around a year ago
Ignored
That was a couple of years ago - I spent more hours on ALF than I care to remember, most of them trying to get the median thingy to work in MQL4...
Old Benjamin was right
 
 
  • Post #13
  • Quote
  • Jun 11, 2011 7:33pm Jun 11, 2011 7:33pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
This is a repost of the indicator from earlier today - in the original post I neglected to include the documentation.
Attached File(s)
File Type: pdf The Inverse Fisher Transform.pdf   621 KB | 3,164 downloads
File Type: mq4 Smoothed_RSI_EhlersIFT.mq4   2 KB | 1,600 downloads
Old Benjamin was right
 
 
  • Post #14
  • Quote
  • Edited 5:56pm Jun 12, 2011 4:04am | Edited 5:56pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting Lou G
Disliked
No need to do the "false","true" thing when using arrays as Series - ArrayResize always adds a new slot to the "right " end ...
Ignored
Lou,

I went thru the thread you mentioned. To mimic indicator buffers with arrays, one must keep their size to Bars and shift them on a new bar. Zen Leow's advices are spot on, he suggests shifting every element in array within a loop of Bars extent. As this can be quite time-consuming, rangebound suggests the AsSeries flip and finally concludes that if the array is AsSeries right from the start, then the ArrayResize() always shifts the data in desired direction. I dare to say the assumption is wrong.

stored elements in array (regardless if AsSeries or not):
data A B C D E

point of view if not set AsSeries:
indx 0 1 2 3 4
data A B C D E

point of view if set AsSeries - this is like buffer, current bar = E:
indx 4 3 2 1 0
data A B C D E

Now, if I apply ArrayResize(), it will add/remove space at highest index, it will be on the right side (at current bar) only if the array is not set AsSeries. Data don't flip, only the index does. I need to keep the arrays AsSeries during calculation (iMAOnArray, iRSIOnArray) and if I keep them so and resize, new space will be added "prior to the leftmost bar", leaving the data where it was. But if I flip the index to "normal", ArrayResize() will make a new space (with index 5 for data F - the new bar), then flipping the index back will be zero for F - and the array shifted as a bonus It seems the elements are really sequentially "hardwired" in mql4, like a contiguous file in memory or on disk.

Well, it will work only until Bars don't reach MaxBarsOnChart.. so the indicator I posted in #2 is flawed with this disease - it will stop drawing if the barcount on chart is full. I can't edit post #2 anymore. I apologize, I hope I have fixed it and this one will be the 'final' beta

edit: seems there's no need to worry with the bars issue, mt4 carelessly keeps adding bars over limit (see pic - MaxBarsInChart = 200, currently Bars=229, it falls back to 200 again after restart) so both indicators posted should work fine.
Attached Image
Attached File(s)
File Type: mq4 SVE RSI I-Fish.mq4   6 KB | 1,225 downloads
MarginTrader All Time Return: -2.4%
 
 
  • Post #15
  • Quote
  • Edited 12:28pm Jun 12, 2011 9:55am | Edited 12:28pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
I resolved the Bars issue a while ago by setting max bars (both history and chart) to a billion-1 (tools/chart).

Perhaps I am wrong but I understood Zen Leow's shifting routine to be necessary only for arrays used in "normal" fashion (left to right) which I never do since MT4 is oriented to use right to left.

Attached is another Ehlers indicator that I've converted from TradeStation that simply could not function correctly if Rangebound's explanation was incorrect.

I suppose the only way to put this to bed is to write a small chunk of code to specifically test and print the various possibilities - perhaps I'll do just that when I find time.

If I had my way I'd write everything in Python (or the new Java)...
Attached File(s)
File Type: mq4 #MAMA_v2.mq4   6 KB | 1,259 downloads
Old Benjamin was right
 
 
  • Post #16
  • Quote
  • Edited 4:40pm Jun 12, 2011 4:11pm | Edited 4:40pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting Lou G
Disliked
Attached is another Ehlers indicator that I've converted from TradeStation that simply could not function correctly if Rangebound's explanation was incorrect....
Ignored
Yes, i see ..and i already see a reason: you're not setting them ArraySetAsSeries(arrayX, true)!! You have no need to do so; you simply declare the array (every array is not AsSeries by default) and make all the computations "manually", indexing them "backwards" as you go (from right to left) ..in fact, indexing doesn't matter to you, if you keep the calc on the right track with the index. That's why simple ArrayResize(arrayX, Bars) works for you. It adds a slot on the right side. But I was lazy to calculate LWMA, EMA and RSI doing plain math so I use the iMAOnArray() and iRSIOnArray() functions of mql4. Implementation of these 'instant' functions is somehow st*pid and MQ was criticized for it - they calculate from left to right (leftmost bar=0) and if you want to do a MA or RSI on a mt4-style indexed time series, the prepared array has to be ArraySetAsSeries(arrayX, true). Otherwise the iMA/iRSIOnArray returns nonsense. But if AsSeries, then ArrayResize() adds a slot on the left side, hence the necessary flip and hence Rangebound's statement "let's set'em all AsSeries and resize" is wrong, i can't help myself. Resizing to Bars alone will do the job only if not AsSeries=true, as with your #MAMA_v2 (very nice indicator, thanks!).

Yes, mql4 is "easy" but seems to be weird sometimes..
MarginTrader All Time Return: -2.4%
 
 
  • Post #17
  • Quote
  • Edited 6:09pm Jun 12, 2011 5:58pm | Edited 6:09pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
Actually it works just as well either way, as long as you declare the array as series to use iMAOnArray or the other array functions.

Sorry to throw you a curve ball - I actually thought I had those arrays declared as series. Must have overlooked it when I did the coding

EDIT: I honestly didn't set out to confuse things. I've gone back and declared the arrays as series in init() as I should have done in the beginning.
Old Benjamin was right
 
 
  • Post #18
  • Quote
  • Jun 12, 2011 6:26pm Jun 12, 2011 6:26pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting Lou G
Disliked
Actually it works just as well either way, as long as you declare the array as series to use iMAOnArray or the other array functions.

Sorry to throw you a curve ball - I actually thought I had those arrays declared as series. Must have overlooked it when I did the coding

EDIT: I honestly didn't set out to confuse things. I've gone back and declared the arrays as series in init() as I should have done in the beginning.
Ignored
LOL that starts to be funny :-)) PLEASE believe me, as a newb the last thing i wanna do is rant on somebody I really appreciate. But i did the same inbetween, put this
Inserted Code
[font=Courier New]ArraySetAsSeries(Price,true);[/font]
[font=Courier New]ArraySetAsSeries(Smooth,true);[/font]
[font=Courier New]ArraySetAsSeries(Detrender,true);[/font]
[font=Courier New]ArraySetAsSeries(Q1,true);[/font]
[font=Courier New]ArraySetAsSeries(I1,true);[/font]
[font=Courier New]ArraySetAsSeries(I2,true);[/font]
[font=Courier New]ArraySetAsSeries(Q2,true);[/font]
[font=Courier New]ArraySetAsSeries(Re,true);[/font]
[font=Courier New]ArraySetAsSeries(Im,true);[/font]
[font=Courier New]ArraySetAsSeries(SmoothPeriod,true);[/font]
[font=Courier New]ArraySetAsSeries(Period_,true);[/font]
[font=Courier New]ArraySetAsSeries(Phase,true);[/font]
[font=Courier New]ArraySetAsSeries(MAMA,true);[/font]
[font=Courier New]ArraySetAsSeries(FAMA,true);[/font]
into init(). I didn't want to wait for the the lazy market to show the same thing I got out of the visual tester - see the attached pic, red line marks start of drawing. It looks ok when put on chart, then it starts to be fun .. that's the kinda 'repaint' i meant before.. if you embed the ArrayResize() with the false/true thingy, it reverts to correct behavior.
Attached Image (click to enlarge)
Click to Enlarge

Name: mama_asarray.gif
Size: 18 KB
MarginTrader All Time Return: -2.4%
 
 
  • Post #19
  • Quote
  • Jun 12, 2011 7:43pm Jun 12, 2011 7:43pm
  •  Lou G
  • Joined May 2006 | Status: Only one user name... | 1,367 Posts
The really odd thing is that I had an EA using MAMA running for the entire week 6/6 - 6/10, never shut it down and saw no bad behavior at all...

And it earned 121 pips for the week.

EDIT: I have two versions running now - one with true/false, one without.
Old Benjamin was right
 
 
  • Post #20
  • Quote
  • Edited 9:29pm Jun 12, 2011 8:18pm | Edited 9:29pm
  •  MaryJane
  • Joined Jun 2011 | 702 Posts
Quoting Lou G
Disliked
The really odd thing is that I had an EA using MAMA running for the entire week 6/6 - 6/10, never shut it down and saw no bad behavior at all...

And it earned 121 pips for the week.
Ignored
¨
Congrats on the pips! And your MAMA is perfect, because the arrays are NOT set AsSeries.
MarginTrader All Time Return: -2.4%
 
 
  • Platform Tech
  • /
  • Mt4 code for smoothed inverse fisher transform of RSI
  • Reply to Thread
    • Page 1 2
    • Page 1 2
0 traders viewing now
  • More
Top of Page
  • Facebook
  • Twitter
About FF
  • Mission
  • Products
  • User Guide
  • Media Kit
  • Blog
  • Contact
FF Products
  • Forums
  • Trades
  • Calendar
  • News
  • Market
  • Brokers
  • Trade Explorer
FF Website
  • Homepage
  • Search
  • Members
  • Report a Bug
Follow FF
  • Facebook
  • Twitter

FF Sister Sites:

  • Metals Mine
  • Energy EXCH
  • Crypto Craft

Forex Factory® is a brand of Fair Economy, Inc.

Terms of Service / ©2023