VSA Screener recognizing patterns and SOSBar and SOWBar bars.
1 = SOSBar bars upward strength
2 = SOWBar bars or signs of downward strength.
All bullish or bearish move has to be confirmed by the next bar indicator and signals you can find in this page: TAC VSA BAR SIGNALS V1.1.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 |
//defparam calculateonlastbars=2000 Subasta=0 vol=volume/10 If Subasta=1 then b=close > low and volume > high ce=close < high and volume > low if b or ce then v=volume else v=0 endif endif if Subasta=0 then v=volume endif MediaVol=60 volAvg=average[MediaVol](v) TLL = LinearRegressionSlope[40](close) //============================================= EURO ======================================= // = // = //=========================================================================================== if vol>(4*volAvg) then Volpos=1 elsif v>(3*volAvg) then Volpos=1 elsif v>(volAvg) then Volpos=2 Volpos=3 elsif v<(volAvg) then Volpos=4 elsif v<(volAvg)*0.5 then Volpos=5 else Volpos=0 endif //============================================= END VOLUME ================================= // = // = //=========================================================================================== spread = (high-low) avgSpread = average[40](spread)[1] widerangebar= (spread >avgSpread*1.8) widerangebarmid= (spread >avgSpread*1.5) narrowrangebar= spread < AvgSpread*0.7 upbar = close>close[1] downbar= close<close[1] //upclose = close>=((spread*0.7)+low)// close is above 70% of the bar //downclose = close<=((spread*0.3)+low)// close is below the 30% of the bar //aboveclose = close>((spread*0.5)+low)// close is between 50% and 70% of the bar //belowclose = close<((spread*0.5)+low)// close is between 50% and 30% of the bar //midclose = close>((spread*0.3)+low) and close<((spread*0.7)+l)// close is between 30% and 70% of the bar upclose = close>=((spread*0.7)+low)// close is above 70% of the bar downclose = close<=((spread*0.3)+low)// close is below the 30% of the bar midclose = close>=((spread*0.3)+low) and close<=((spread*0.7)+low)// close is between 30% and 70% of the bar if close<=((spread*0.2)+low) then ClosePos =1 elsif close<=((spread*0.4)+low)then ClosePos =2 elsif close<=((spread*0.6)+low)then ClosePos =3 elsif close<=((spread*0.8)+low)then ClosePos =4 ClosePos =5 else ClosePos =0 endif //========================trend estimation ========================= //minpRWIs = 1 //maxpRWIs = 5 RWIHi=0 RWILo=0 i=5 //RWIHi=(high-low[i])/((averagetruerange[i](close[0]))*SQRT(i))/RWIHi=MAX((high-low[i])/((averagetruerange[i](close[0]))*SQRT(i)),RWIHi) //RWILo=(high[i]-low)/((averagetruerange[i](close[0]))*sqrt(i))/RWILo=MAX((high[i]-low)/((averagetruerange[i](close[0]))*sqrt(i)),RWILo) RWIHi=(high-low[i])/((averagetruerange[i](close[0]))/SQRT(i)) RWILo=(high[i]-low)/((averagetruerange[i](close[0]))/sqrt(i)) RWIHi=Max(RWIHi,RWIHi) RWILo=Max(RWILo,RWILo) //k = RWIHi- RWILo ground = RWIHi //minpRWIl = 1 //maxpRWIl = 20 ix=25 //RWIHi=(high-low[i])/((averagetruerange[i](close[0]))*SQRT(i))/RWIHi=MAX((high-low[i])/((averagetruerange[i](close[0]))*SQRT(i)),RWIHi) //RWILo=(high[i]-low)/((averagetruerange[i](close[0]))*sqrt(i))/RWILo=MAX((high[i]-low)/((averagetruerange[i](close[0]))*sqrt(i)),RWILo) RWIHi=(high-low[ix])/((averagetruerange[ix](close[0]))/SQRT(ix)) RWILo=(high[ix]-low)/((averagetruerange[ix](close[0]))/sqrt(ix)) RWIHi=Max(RWIHi,RWIHi) RWILo=Max(RWILo,RWILo) j = RWIHi-RWILo j2 = RWIHi If ground > 1 then upimd=1 else upimd=0 endif If j>1 then upmajor = 1 elsIf j<1 then upmajor =-1 else upmajor=0 endif If j2>1 then upminor=1 else upminor=-1 endif //======================================================================| // VSA Signal generation | //======================================================================| upthrustbar = ( wideRangeBar and (ClosePos=1 or ClosePos=2) and upminor>0 and high>high[1] and (upimd>0 or upmajor>0)and Volpos <4) upthrustbartrue = wideRangeBar and ClosePos=1 and upmajor>0 and high>high[1] and Volpos <4 upthrustcond1 = upthrustbar[1] and downbar and not narrowrangebar upThrustCond2 =upThrustBar[1] and downBar and Volpos = 2 upThrustCond3 =upThrustBar and Volpos =1 sellcond1 = (upthrustcond1 or upthrustcond2 or upthrustcond3) sellCond2 =sellCond1[1]=0 sellcond = sellcond1 and sellcond2 strengthdown = volpos<4 and downbar[1] and upbar and closepos>3 and upimd<=0 and upminor<0// strength after a down trend strengthdown1 = upmajor<0 and v>(volavg*1.5) and downbar[1] and upbar and closepos>3 and upminor<0 and upimd<=0//strength after downtrend . high v buycond1 = strengthdown or strengthdown1 buycond = upbar and buycond1[1] stopv =low=lowest[5](low) and (upClose or midClose) and v>4*volAvg and tll<0 and widerangebarmid and downbar STOPPINGVOLUME=( downbar and low=lowest[20](low) and (widerangebar) and (midclose or upclose) and Volpos<3 ) revupthrust = tll<0 and upbar and upclose and v>v[1] and v>volavg and widerangebar and downbar[1] and downclose[1] and upminor<0 effortup =upbar and upclose and (widerangebar) and (Volpos<4 ) and close>=((high-low)*0.7+low) //and (coratio > midbodyratio) // checking for close near high effortDown =( downbar and downclose and (widerangebar) and (Volpos<5) and low=lowest[5](low) )//and (coratio > midbodyratio) // checking for open near high if Effortup or stopv or STOPPINGVOLUME or revupthrust or buycond then x=1 elsif effortDown or upthrustbar or upthrustbartrue or sellcond then x=2 else x=0 endif SCREENER[x](x AS "1=SOSBar,2=SOWBar,0=NoSignal") |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :
Filename : download the ITF files
How to import ITF files into ProRealTime platform?
PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials