Violet

Williams Swing Points

Category: Screeners By: Violet Created: November 21, 2017, 9:01 AM
November 21, 2017, 9:01 AM
Screeners
12 Comments
Williams Swing Points

Stock screener based on Williams Highs and Lows indicator made by @gabri

 

//Williams SwingPoints
// 20-11-2017
// Violet, extension of on Gabri's algo

//Test for insidebar
insidebar = high < high[1] and low > low[1]
if not insidebar and high > alto[1] then
 alto = high
 basso = low
 markup = barindex
 markhigh = high
endif
if not insidebar and low < basso[1] then
 alto = high
 basso = low
 markdown = barindex
 marklow = low
endif

if alto < alto[1] and trend = 1 then
 trend = 0
 thisbar = markup
 mediummarkup = shortmarkup
 shortmarkup = markup
 longmarkhigh = mediummarkhigh
 mediummarkhigh = shortmarkhigh
 shortmarkhigh = markhigh
 if longmarkhigh < mediummarkhigh and mediummarkhigh > shortmarkhigh then
  longmarkUpset = 1
  thisbar = mediummarkup
 else
  longmarkUpset = 0
 endif
endif

if basso > basso[1] and trend = 0 then
 trend = 1
 thisbar = markdown
 mediummarkdown = shortmarkdown
 shortmarkdown = markdown
 longmarklow = mediummarklow
 mediummarklow = shortmarklow
 shortmarklow = marklow
 if longmarklow > mediummarklow and mediummarklow < shortmarklow then
  longmarkDownset = 1
  thisbar = mediummarkdown
 else
  longmarkDownset = 0
 endif
endif

whichbar = barindex - thisbar
LookbackPeriods = 1

signalUP1 = trend = 1 and not longmarkUPset and whichbar <= LookbackPeriods
signalUp2 = trend = 1 and longmarkUpset and whichbar <= LookbackPeriods
signalDn1 = trend = 0 and not longmarkDownset and whichbar <= LookbackPeriods
signalDn2 = trend = 0 and longmarkDownset and whichbar <= LookbackPeriods

if signalup1 then
 type = 1 // arrowup
elsif signalup2 then 
 type = 2 // ellipse at bottom
elsif signalDn1 then
 type = -1 // arrowdown
elsif signalDn2 then
 type = -2 // ellipse at top
endif

signal = SignalUP1 OR signalUP2 or SignalDn1 OR signalDn2

screener [ signal ] sort by type

 

Download
Filename: Williams-Swing-Point.itf
Downloads: 725
Violet
Violet Master
Currently debugging life, so my bio is on hold. Check back after the next commit for an update.
Author’s Profile

Comments

fab.ub
6 years ago
#

HI GABRI, if the cirled arrow is the intermediate point in which You can define your entry and stop loss what is the meaning of the other arrows (without circle)?

gabri
9 years ago
#

Violet, you did an excellent job. I attached here https://www.prorealcode.com/prorealtime-indicators/williams-highs-lows/ also my version of the screener.

Abz
Abz
9 years ago
#

Violet , when trying to automate this my trades are not opening at the same entry point as where this circle are drawn, have you tried that?

Violet
9 years ago
#

Abz, the arrows and circles are only the *first part* of a trade setup. If certain conditions are met (as defined in the algorithm), then the signal comes on the bar/candle immediately following the arrow/circle, which forms the *second part* of the setup. Please carefully read the comments/discussions on the "Wlliams' Highs And Lows" indicator, presented by Gabri, on which this screener is based. It is by design that the actual trade signal (entry or exit point) can only come on the following bar/candle. The two bars/candles work in tandem to produce the signal. Mind you, never use indicators and screeners if you do not know exactly what conditions they are searching for.

BZH22
9 years ago
#

Merci Gabri pour les MM50 et MM200

gabri
9 years ago
#

BZH22, i don't understand why the indicators and the screeners are not working on your computer. Try to check the settings because on mine it runs smoothly. For you can add: c3=average[50](close)>average[200](close) screener[c1 and c3 and not c2] (c1)

BZH22
9 years ago
#

Bonjour Gabri ton screener ne marche pas . tu peux créer un screener à l' achat, avec avec flêche plus ellipse et MM50 > MM200 . Cordialement .

gabri
9 years ago
#

BZH22, i don't understand why the indicators and the screeners are not working on your computer. Try to check the settings because on mine it runs smoothly. For you can add: c3=average[50](close)>average[200](close) screener[c1 and c3 and not c2] (c1)

gabri
9 years ago
#

Try also Violet screener, it seems really good.

BZH22
9 years ago
#

Bonjour . il faudrait créer un screener qui détecte toutes les actions avec une flêche plus ellipse a l' achat .

gabri
9 years ago
#

if (high>alto[1]) and not (highlow[1]) then alto=high basso=low markup=barindex markhigh=high endif if (low<basso[1]) and not (highlow[1]) then alto=high basso=low markdown=barindex marklow=low endif if alto<alto[1] and trend=1 then trend=0 mediummarkup=shortmarkup shortmarkup=markup longmarkhigh=mediummarkhigh mediummarkhigh=shortmarkhigh shortmarkhigh=markhigh //intermediate high swing points if longmarkhighshortmarkhigh then imhighold=imhighnew imhighnew=mediummarkhigh //refhigh=shortmarkup endif if imhighold>imhighnew then refhigh=mediummarkup endif endif if basso>basso[1] and trend=0 then trend=1 mediummarkdown=shortmarkdown shortmarkdown=markdown longmarklow=mediummarklow mediummarklow=shortmarklow shortmarklow=marklow //intermediate low swing points if longmarklow>mediummarklow and mediummarklow<shortmarklow then imlowold=imlownew imlownew=mediummarklow //reflow=shortmarkdown endif if imlowold<imlownew then reflow=mediummarkdown endif endif //long conditions c1=imlowold=mediummarklow //short conditions c2=imhighold>imhighnew and (highest[barindex-refhigh+1](high))<=mediummarkhigh screener[c1 and not c2] (c1)

gabri
9 years ago
#

Thanks Violet, You can try also this version (for long only)

ProRealCode ProRealCode
Loading...