zup pattern scanner

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
this will be about a scanner for patterns found by eugeni neumoin's zup indicators...... specifically version, 93.....

the zup_93 below is nen's original code for the 93...... it will not compile in current compilers..... you must use something like a build 509 compiler......

the zup 1, is my edited version on nen's 93..... look at the mq4 code and search for 'hayseed' to see my edits..... nothing fancy......

the zup scanner is a script..... it will compile with current metatrader compilers.....
//------

the zup 1.mq4 will not compile with current platforms..... i compiled zup 1 with a 509 platform compiler..... it's the zup 1.ex below......

the hitch is, some things written many years ago will only compile with platforms from those years.....

i'm sure this is confusing...... will post some more explaining things better.....

the bottom line is, you need zup 1.ex in your indicator list and the zup pattern scanner in your scripts......h
//-----

//-----

nzdcad-d1-oanda-division1.png

//-----
 

Attachments

  • zup pattern scanner.mq4
    1.1 KB · Views: 73
  • zup pattern scanner.ex4
    6.2 KB · Views: 46
  • ZUP_v93.mq4
    427.3 KB · Views: 72
  • zup 1.ex4
    160.8 KB · Views: 48
  • zup 1.mq4
    428.9 KB · Views: 66
  • 👍
Reactions: Mehreen and Enivid

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
below are some pdfs on harmonic patterns.....

we can all shoot from the hip..... waiting on patterns could be a good way to practice taking better shots..... the thought being it might be an exercise in patience.....

i have started coding a stand alone harmonic scanner that will draw from within itself all the functions needed rather than using icustom...... doing so gives the ability to restrict the results to only patterns of a certain age.....

have the ab=cd pattern complete.....h
//-----
 

Attachments

  • harmonicpatterns.pdf
    736.3 KB · Views: 32
  • harmonic pattern trading.pdf
    3 MB · Views: 63

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
looked at the zupv122 and v129 code today....... the ones below should compile with all platforms without errors..... they were not errors in the true sense, only that mq4 has changed over the years...... this is common.....

there will be considerable warnings however..... those warnings are more for coders.... just to give us a heads up to make sure it is as expected.....

so now when you compile the code you know what's in it...... it's safer this way.....h
//------
audcad-d1-oanda-division1-zup-v129.png

//-----
audcad-d1-oanda-division1-zup-122.png
 

Attachments

  • ZUP_v129 repaired2020.ex4
    1 MB · Views: 34
  • ZUP_v122 repaired2020.ex4
    1,007.9 KB · Views: 28
  • ZUP_v129 repaired2020.mq4
    1.3 MB · Views: 56
  • ZUP_v122 repaired2020.mq4
    1.2 MB · Views: 48

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
Code:
// bullish bat
           if((x < a) && (b < a) && (b < c) && (d < c) && (c < a) && (x < d) && (x < b) && (d < b) && (((a-b)/(a-x)) > 0.38) && (((a-b)/(a-x)) < 0.5) && (((c-b)/(a-b)) > 0.38) && (((c-b)/(a-b)) < 0.886) && ( ((c-d)/(c-b)) < 2.61)  && ( ((c-d)/(c-b)) > 1.68) && (((a-d)/(a-x)) < 0.86) )

Code:
// bearish bat
           if((a < x) && (a < b) && (c < b) && (a < c) && (c < d) && (d < x) && (b < d) && (a < d) && (((b-a)/(x-a)) < 0.5) && (((b-a)/(x-a)) > 0.382) && (((b-c)/(b-a)) < 0.886) && (((b-c)/(b-a)) > 0.382) && (((d-c)/(b-c)) < 2.618) && (((d-c)/(b-c)) > 1.682) && (((d-a)/(x-a)) < 0.886 ))
 
Last edited:

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
Code:
// bearish butterfly         
           if((a < x) && (a < b) && (a < c) && (a < d) && (b < x) && (b < d) && (c < b) && (c < d) && (c < x) && (b < x) && (b < d) && (x < d) && ((b-a) < 0.786*(x-a)) && ((b-c) < 0.886*(b-a)) && ((b-c) > 0.382*(b-a)) && ((d-c) > 1.618*(b-c)) && ((d-c) < 2.618*(b-c)) && ((d-a) < 1.618*(x-a)) && ((d-a) > 1.27*(x-a)) )



//-----

           // bullish butterfly
           if((x < a) && (x < b) && (x < c) && (b < a) && (b < c) && (d < x) && (d < a) && (d < b) && (d < c) && (((a-b)/(a-x)) < 0.786) && (((c-b)/(a-b)) < 0.886) && (((c-b)/(a-b)) > 0.382) && (((c-d)/(c-b)) < 2.618)  && (((c-d)/(c-b)) > 1.618) && (((a-d)/(a-x)) < 1.618) && (((a-d)/(a-x)) > 1.27) )

//-----

bullish bearish butterfly.png
 

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
Code:
// bearish cypher
           if((a < x) && (a < b) && (a < d) && (b < d) && (b < x) && (c < x) && (c < a) && (c < b) && (c < d) && (d < x) && ((b-a)/(x-a) < 0.618) && ((b-a)/(x-a) > 0.382) && (((b-c)/(b-a)) > 1.272) && (((b-c)/(b-a)) < 1.414) && (((x-a)/(d-c)) < 0.786) )


//------

           // bullish cypher
           if((x < a) && (x < b) && (x < c) && (x < d) && (a < c) && (b < a) && (b < c) && (d < a) && (d < b) && (d < c) && (((a-b)/(a-x)) < 0.618) && (((a-b)/(a-x)) > 0.382) && (((c-b)/(a-b)) < 1.414) && (((c-b)/(a-b)) > 1.13) && (((c-d)/(c-x)) < 0.786) )

//------

bullish bearish cypher.png
 

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
nen's zup_v62 should now compile on any platform without errors.....

there will be warnings...... in this case they can be overlooked..... some of nen's indicators are over 16,000 lines of code..... with that much you will quickly run out of convenient variable names..... so he reuses some repeatedly.....

will post more versions later.....h
//-----
gbpnzd-m30-oanda-division1-zup-v62.png
 

Attachments

  • ZUP_v62.ex4
    406.7 KB · Views: 24
  • ZUP_v62.mq4
    464.5 KB · Views: 31

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
you can do this..... from memory.... in your head..... if there is interest, i'll expand.....
//----

but first, imagine this......

a draftsman might draw construction plans for some building..... the builder might go to the draftsman several times with revisions or things left out in his original request..... day in day out same thing with different builders with different revisions different plans..... never knowing when a builder might come back he stacks a copy of every version on top of thousands of others......

a time will come when there is no room left..... he cleans house..... many of us do the same with code......
//------

quite often i'll mention scanning every pair on every time frame...... if there is interest, i'll expand this to the maximum limit.....

here is an example..... the scanner is a script, goes in the scripts folder..... the ZUP_v93 h, is a modified version on nens original indicator, goes in the indicators folder..... you need both......

within reason, you can scan for almost everything.....h
//----


//-----
 

Attachments

  • ZUP_93 h.ex4
    772.4 KB · Views: 29
  • ZUP_93 h.mq4
    858.3 KB · Views: 50
  • nen zup scanner.ex4
    6.6 KB · Views: 32
  • nen zup scanner.mq4
    1.3 KB · Views: 51
  • 👍
Reactions: zazzy

Ngoclong

Trader
Aug 3, 2021
1
0
17
22
looked at the zupv122 and v129 code today....... the ones below should compile with all platforms without errors..... they were not errors in the true sense, only that mq4 has changed over the years...... this is common.....

there will be considerable warnings however..... those warnings are more for coders.... just to give us a heads up to make sure it is as expected.....

so now when you compile the code you know what's in it...... it's safer this way.....h
//------
audcad-d1-oanda-division1-zup-v129.png

//-----
audcad-d1-oanda-division1-zup-122.png
hello sir can i get code for alert scanner harmonic zup v150? or another version?
 

zazzy

Newbie
Dec 8, 2021
1
0
1
34
you can do this..... from memory.... in your head..... if there is interest, i'll expand.....
//----

but first, imagine this......

a draftsman might draw construction plans for some building..... the builder might go to the draftsman several times with revisions or things left out in his original request..... day in day out same thing with different builders with different revisions different plans..... never knowing when a builder might come back he stacks a copy of every version on top of thousands of others......

a time will come when there is no room left..... he cleans house..... many of us do the same with code......
//------

quite often i'll mention scanning every pair on every time frame...... if there is interest, i'll expand this to the maximum limit.....

here is an example..... the scanner is a script, goes in the scripts folder..... the ZUP_v93 h, is a modified version on nens original indicator, goes in the indicators folder..... you need both......

within reason, you can scan for almost everything.....h
//----


//-----
I must say this is pure genius @hayseed.... This is very interesting. I have a couple of questions?

1. Can these result be place in a dashboard format instead of alerts?
2. Can the limit be extended?
3. Is there a way this script can be used for other indicators?
4. How can one place a buffer on this indicator which can be used to create an EA

THANKS
 

hayseed

Master Trader
Jul 27, 2010
1,010
258
149
usa
I must say this is pure genius @hayseed.... This is very interesting. I have a couple of questions?

1. Can these result be place in a dashboard format instead of alerts?
2. Can the limit be extended?
3. Is there a way this script can be used for other indicators?
4. How can one place a buffer on this indicator which can be used to create an EA

THANKS
//--

hey zazzy.... yes the same idea can be applied to other indicators..... it works best if the indicators mq4 is available so it can be checked and often modified....

instead of buffers, you'd have to use global variables..... or edit nen's original code to use on a specific pair....

yes it could be re configured as a dashboard..... that would involve more code.....

not sure about the extension, would have to look back at the code and refresh my memory......h