• LIMITED TIME OFFER: use coupon code PRIMEDAY at checkout to save $50 off VIP membership (down to $149 / year). Valid through Tuesday 6/22.

VWAP Cross Scanner for ThinkorSwim

Any one help with this? I would like a scanner (aka to be notified) when a stock in my parameters crossed above or below Intra-Day VWAP.

Thanks Ben. Here's as far as I got. Does it look right to you for an above VWAP criteria?

1) would I need to do a scan (each) for above and below?

2) Would the aggregation period be for an intraday time period or Daily? I would like to be alerted as it happens.

WMOVfK1.png
 

BenTen

Administrative
Staff
VIP
You can use the default Scan tab in ThinkorSwim for this. During the scan editor, just select close for one side, crosses - crosses above - crosses below in the middle option, and select VWAP on the right side.

Almost there, on the left column, select the dropdown > Price > close. Select the timeframe that you want. And yes, you would need to create 2 scans for this.
 

Kuzey

New member
Hello,
I am trying to create a scanner for candles in 10 minutes chart.. Candles at or below standard devchannel middle line and VWAP lower band is crossing MA9 and stays below. Thanks for the help!
 

Vincenzo

New member
Hi all , I am wanting to create a scan that can find stocks which x amount of ticks have been above VWAP, is this possible?

Tick as in each candle. What if a line for the price close was created then create a scan that is below or equal to the close line? To be clear I am looking to scan: Stocks where the last 20 five minute candles lows close above VWAP.
 

luicius

New member
@Vincenzo I'm no expert at thinkscript but see if this works.

Code:
input priceLow = low;
input totalBars = 20;

def myVWAP = reference VWAP()."VWAP";
def lowsAboveVWAP = Lowest(priceLow,totalBars) > myVWAP;

plot scan = lowsAboveVWAP;

results:

Q8XQMd4.png
 

Vincenzo

New member
Hello all,

I am trying to use this code to search for stocks where the last 20 five minute candles closed above VWAP. I am having trouble creating the correct settings in the study to create this. How would I use this code to search for the desired parameters ?

Code:

Code:
input priceLow = low;
input totalBars = 20;

def myVWAP = reference VWAP()."VWAP";
def lowsAboveVWAP = Lowest(priceLow,totalBars) > myVWAP;

plot scan = lowsAboveVWAP;

thank you!

eU22FZq.png


I have tried changing that too with no luck. The screen shot from @luicius was the exact result i am looking for

I found my solution:

Add a study filter with 5-min aggregation and use the following code to find symbols with last 20 bars having low price greater than cumulative VWAP for that day:

Code:
def cumulativeVWAP = reference VWAP;
plot scan = sum(low > cumulativeVWAP, 20) == 20;
 

BenTen

Administrative
Staff
VIP
@Vincenzo It's actually not complicated at all and you don't even need any external script.

Start by setting up a scanner to look for close crossing above VWAP.

xBen1h9.png


Adjust the within X bars value. By default, it's set to one, so it will be scanning for the latest bar. This field is optionable. I would leave it as 1.

Next, select the timeframe before you hit the Scan button.

HUSAnar.png
 

Shawtysto

New member
Heres what I have in the condition wizard:

Code:
close is greater than or equal to reference VWAP()."VWAP" and close is less than or equal to reference VWAP()."VWAP".

I need help with percentages. I want the close to be 2% greater than or equal to reference VWAP(). "VWAP" In addition, I want the close to be 2% less than or equal to reference VWAP(). "VWAP".

Also, I would like a code for the close to be 2% less than or equal to the 52 week high.

Thank You.
 

ztrader

New member
Hello, would appreciate any help i can get. Here we go
  • The stock has moved x standard deviations under the vwap at any time of the day, intraday with increasing volume.
  • The price is closing back to the vwap after been X SD under the vwap (with less volume)
On TOS I can scan after stocks that have been X% under the VWAP alone, but cannot combine it with the last parameter mentioned above. Would appreciate any help.
 

Bendu

Member
VIP
@Shawtysto Change the close is greater than or equal VWAP filter to this:

Code:
close is greater than or equal to reference VWAP()."VWAP" * .98 and close is less than reference VWAP ()."VWAP" * 1.02
 

pga0008

Member
Can I ask - how would you adjust this so that it would only pull stocks that just crossed in the last 5 minutes, not stocks that crossed an hour ago that are still above the VWAP. I am trying to scan for only NEW crosses

Y81U4MS.png
 

pga0008

Member
I have done that but what its doing is then pulling all stocks that are “still above”. What I’m looking to scan for are those stocks that within the last 5 minutes “just crossed”
 

pga0008

Member
And if I set it to 5 minutes it will only shows symbols that just crossed (ie: 5 minutes ago)in the watch list? Can i set it to 1 min or will it not work that fast?
 

Similar threads

Top