# Raghee Horner VWAP Max Tool Indicator for ThinkorSwim

#### ljones

##### New member
I'm curious to know how Simpler Trading came up with their VWAP Max Tool Package indicator for ThinkorSwim. How does TOS calculate the VWAP line? It looks like they are starting each day from the open rather than summing from the beginning of the chart's period. Is this a correct interpretation? I am interested in VWAP on the daily chart. I find the Anchored VWAP is lining up with hand calculations but deviating big time from the TOS VWAP.

FYI: The VWAP Max Tool from Simpler Trading or Raghee Horner is the same as one of the Anchored VWAP indicator that Ben posted in this thread.

Additionally, you can even use the script below.

Code:
``````# n Bars VWAP
# Nube 6.24.19
#

input length = 20;
input price  = vwap;

def p = if IsNaN(price) then p[1] else price;
def v = if IsNaN(volume) then v[1] else volume;

plot VWAP = if IsNaN(price) then Double.NaN else
Sum(p * v, length) / Sum(v, length);``````

Last edited by a moderator:
@ljones That's correct. VWAP will start fresh at the beginning of each day. You can find more info about it here. The Anchored VWAP indicator will allow you to use it on different timeframes.

Last edited:

### BenTen's Watchlist + Setup + Trade Recaps

Are you aware of a vwap for TOS that works on a range bar chart? The standard vwap seems to work only on minute charts. Thanks!

Last edited:
@Slip VWAP doesn't support Range Bars

Last edited by a moderator:
I too would like to see the coding for a VWAP for Range bars. Hopefully it will work on Renko as well. I've tried it myself, but can't seem to get it to plot.

Last edited by a moderator:
I too would like to see the coding for a VWAP for Range bars. Hopefully it will work on Renko as well. I've tried it myself, but can't seem to get it to plot.
VWAP doesn't support Range Bars

### New Indicator: Buy the Dip

VWAP 9EMA Crossover Study Questions 0
VWAP with a volume spike alert Questions 1
vwap Questions 3
EMA + VWAP + MACD Buy/Sell Signal Questions 3
VWAP coding request Questions 2

87k+ Posts
375 Online

## The Market Trading Game Changer

Join 2,500+ subscribers inside the useThinkScript VIP Membership Club
• Exclusive indicators
• Proven strategies & setups
• Private Discord community
• Exclusive members-only content
• 1 full year of unlimited support

What is useThinkScript?

useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.

How do I get started?

We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.

If you are new, or just looking for guidance, here are some helpful links to get you started.

What are the benefits of VIP Membership?