Trading with Market Statistics. IV Standard Deviation - Page 2 - Traders Laboratory

Go Back   Traders Laboratory > Trading Laboratory > Market Profile®

Market Profile® Are you a market profile trader? Post here.

Reply
 
LinkBack (6) Thread Tools Search this Thread Display Modes
  #11 (permalink)  
Old 07-24-2007, 10:20 PM
Dogpile Dogpile is offline
Dogpile has no status.

 
Join Date: May 2007
Posts: 577
Thanks: 0
Thanked 6 Times in 4 Posts
Re: Trading with Market Statistics. IV Standard Deviation

<<Are you using the VWAP that is on tradestation boards ? and from there on aplying sd ?...>>

VWAP_H is the code I am using -- Tradestation has this as a keyword. indicator can be written simply as:

plot1(vwap_h,"vwap");

--------------

here is how I wrote Std Dev:

first taking the squared difference of 'price' and VWAP_H and summing them:

value1=
square(c-vwap_h)+
square(c[2]-vwap_h[2])+...

then taking square root of value1 gives you std dev, written in EL as:
value2=squareroot(value1/n);

where n is the number of periods...

I just put it up on the tradestation forum to try to get some help:

https://www.tradestation.com/Discuss...Topic_ID=66888

any help here would be appreciated...


Last edited by Dogpile; 07-24-2007 at 10:24 PM.
Reply With Quote
  #12 (permalink)  
Old 07-24-2007, 10:34 PM
jperl's Avatar
jperl jperl is offline
jperl has no status.

Trader Specs
 
Join Date: Sep 2006
Location: Rochester,NY
Posts: 272
Thanks: 0
Thanked 48 Times in 25 Posts
Send a message via AIM to jperl
Re: Trading with Market Statistics. IV Standard Deviation

Quote:
View Post
here is how I wrote Std Dev:

first taking the squared difference of 'price' and VWAP_H and summing them:

value1=
square(c-vwap_h)+
square(c[2]-vwap_h[2])+...

then taking square root of value1 gives you std dev, written in EL as:
value2=squareroot(value1/n);

where n is the number of periods...
Dogpile, you left out an important term in your variance computation. Remember that the VWAP is volume weighted. so you need to weight each one of your square terms by the normalized volume:
value1= Pi*square(c-vwap_h) +..... where Pi= vi/V, vi=volume traded at price c, V=total volume for the distribution.

Also each of the terms in the sum should be the same VWAP :

value1= P1*square(C-VWAP) + P2*square(c[2]-VWAP) + .....

__________________
JERRY

---I'm going to trade til I'm 100, or die trying----

Last edited by jperl; 07-24-2007 at 10:40 PM.
Reply With Quote
  #13 (permalink)  
Old 07-24-2007, 10:58 PM
Dogpile Dogpile is offline
Dogpile has no status.

 
Join Date: May 2007
Posts: 577
Thanks: 0
Thanked 6 Times in 4 Posts
Re: Trading with Market Statistics. IV Standard Deviation

thx Jerry,

note that VWAP_H is hard-coded to already volume-weight for that side of the equation.

I assume you are saying that I need to weight each 'price' observation by volume as well to be consistent? hmm, need to think about this more. can you post a chart of your ES 2-min chart with the bands for today? I would like to see how mine and yours compare as is...

I have been using VWAP a lot lately and using my short-term trading techniques in conjunction with VWAP has so far been awesome -- and I will be thinking a lot about more ideas with VWAP. Look how NQ stopped just short of previous days VWAP again near 55.00 to offer a spot to look for a key reversal... this was sweet since my short-term entry techniques didn't signal a short until then anyway -- but gave extra confidence that this was actually typical behavior for the very volatile NQ contract.

Reply With Quote
  #14 (permalink)  
Old 07-24-2007, 11:05 PM
Dogpile Dogpile is offline
Dogpile has no status.

 
Join Date: May 2007
Posts: 577
Thanks: 0
Thanked 6 Times in 4 Posts
Re: Trading with Market Statistics. IV Standard Deviation

<<Also each of the terms in the sum should be the same VWAP :

value1= P1*square(C-VWAP) + P2*square(c[2]-VWAP) + .....>>

this is not intutive to me... I would then be comparing the current vwap to old prices..

I am thinking about how bollinger bands work here and applying same concept. I am quite familiar with properties of bollinger bands so this is natural for me. bollinger bands compare the price to the moving average value that occured at the same time that the price occured. this is kind of like 'matching' concept in accounting.

I do not know how to code it your way so will look for others for help. But this entire line of thinking is quite stimulating for new ideas.

Reply With Quote
  #15 (permalink)  
Old 07-25-2007, 12:19 AM
nickm001 nickm001 is offline
nickm001 has no status.

 
Join Date: Jan 2007
Posts: 75
Thanks: 0
Thanked 2 Times in 2 Posts
Re: Trading with Market Statistics. IV Standard Deviation

Jerry,
I am also confused with
"Also each of the terms in the sum should be the same VWAP" statement.

Vwap is developing during the day, and is a sum of (pi * vi)/ V. It would seem that SD equitation should have VWAPi and be summed at each bar. So one would get distribution of prices in reference to VWAP line.

Reply With Quote
  #16 (permalink)  
Old 07-25-2007, 05:23 AM
Nick1984's Avatar
Nick1984 Nick1984 is offline
Nick1984 has no status.

Trader Specs
 
Join Date: Dec 2006
Location: Melbourne, Australia
Posts: 442
Thanks: 1
Thanked 0 Times in 0 Posts
Send a message via MSN to Nick1984
Re: Trading with Market Statistics. IV Standard Deviation

I like the strategy that you use but the only thing that I seem to find a bit wrong with it is that you seem to really need to wait a long time for the volume distribution function to develop i.e: you have to wait a long time in the trading day to actually do anything.

Can you add in another factor into your analysis, specifically time? Question being, if you factor in time then you can do a regression analysis based on price, volume, and time so that you can get a probability distribution (90% confidence intervals) to help time trades early on in the trading session.

I might be wrong but it's just an idea

__________________
Nick Constantin

Always look on the bright side of life...da da da da da da da da da - Monty Python
Reply With Quote
  #17 (permalink)  
Old 07-25-2007, 08:40 AM
jperl's Avatar
jperl jperl is offline
jperl has no status.

Trader Specs
 
Join Date: Sep 2006
Location: Rochester,NY
Posts: 272
Thanks: 0
Thanked 48 Times in 25 Posts
Send a message via AIM to jperl
Re: Trading with Market Statistics. IV Standard Deviation

Quote:
View Post

I assume you are saying that I need to weight each 'price' observation by volume as well to be consistent?
Not each price, but each square term in the variance computation

Quote:
View Post
I have been using VWAP a lot lately and using my short-term trading techniques in conjunction with VWAP has so far been awesome -- and I will be thinking a lot about more ideas with VWAP. Look how NQ stopped just short of previous days VWAP again near 55.00 to offer a spot to look for a key reversal... this was sweet since my short-term entry techniques didn't signal a short until then anyway -- but gave extra confidence that this was actually typical behavior for the very volatile NQ contract.
Glad to see you find the VWAP useful. We have a lot more ideas about this coming up.

__________________
JERRY

---I'm going to trade til I'm 100, or die trying----
Reply With Quote
  #18 (permalink)  
Old 07-25-2007, 08:54 AM
jperl's Avatar
jperl jperl is offline
jperl has no status.

Trader Specs
 
Join Date: Sep 2006
Location: Rochester,NY
Posts: 272
Thanks: 0
Thanked 48 Times in 25 Posts
Send a message via AIM to jperl
Re: Trading with Market Statistics. IV Standard Deviation

Quote:
View Post
<<Also each of the terms in the sum should be the same VWAP :

value1= P1*square(C-VWAP) + P2*square(c[2]-VWAP) + .....>>

this is not intutive to me... I would then be comparing the current vwap to old prices..
Yes, that's correct. Think of the following: Suppose you had just one VWAP value say at 12:30 and you wanted to know its variance. You would compute the difference between that value and all the old prices. Take the square of each difference and sum them up to get the unnormalized variance.

__________________
JERRY

---I'm going to trade til I'm 100, or die trying----
Reply With Quote
  #19 (permalink)  
Old 07-25-2007, 09:06 AM
jperl's Avatar
jperl jperl is offline
jperl has no status.

Trader Specs
 
Join Date: Sep 2006
Location: Rochester,NY
Posts: 272
Thanks: 0
Thanked 48 Times in 25 Posts
Send a message via AIM to jperl
Re: Trading with Market Statistics. IV Standard Deviation

Quote:
View Post
I like the strategy that you use but the only thing that I seem to find a bit wrong with it is that you seem to really need to wait a long time for the volume distribution function to develop i.e: you have to wait a long time in the trading day to actually do anything.
Good observation Nick. There is a solution to this which we will eventually get to in later threads having to do with how you incorporate previous days, weeks, months VWAPs and their SD into todays price action. At this point in time, our NEWBIE trader waits for the distribution to develop and also waits for the price action to touch the VWAP. But, coming up in the next thread, we will introduce a paradigm shift in NEWBIE's thinking. Stay tuned.

Quote:
View Post
Can you add in another factor into your analysis, specifically time? Question being, if you factor in time then you can do a regression analysis based on price, volume, and time so that you can get a probability distribution (90% confidence intervals) to help time trades early on in the trading session.
Perhaps you might want to expand on this, to give us an idea of what you are thinking about here.

__________________
JERRY

---I'm going to trade til I'm 100, or die trying----
Reply With Quote
  #20 (permalink)  
Old 07-25-2007, 09:09 AM
Dogpile Dogpile is offline
Dogpile has no status.

 
Join Date: May 2007
Posts: 577
Thanks: 0
Thanked 6 Times in 4 Posts
Re: Trading with Market Statistics. IV Standard Deviation

<<Suppose you had just one VWAP value say at 12:30 and you wanted to know its variance. You would compute the difference between that value and all the old prices. Take the square of each difference and sum them up to get the unnormalized variance.>>

right but when historically charting variance/std dev, don't you want the bands to show what the variance was relative to the distribution at the time of the 'price' reading. for example, lets say you wanted to plot the band that occured at 12:28 (1 bar before 12:30 on a 2-min chart)... you would then want the variance calculated through 1 bar ago, not the 'current' (12:30) VWAP... that is -- you want the distribution up through 12:28 (VWAP_H[1]), not the variance +1 period (the 12:30 VWAP_H) -- right?

Reply With Quote
Reply

LinkBacks (?)
LinkBack to this Thread: http://www.traderslaboratory.com/forums/f6/trading-with-market-statistics-iv-standard-2101.html
Posted By For Type Date
mean trades: Kalman Levels This thread Refback 01-05-2008 02:22 AM
mean trades: December 2007 This thread Refback 01-03-2008 02:48 PM
mean trades This thread Refback 12-25-2007 04:20 PM
how to plot standard deviation of the vwap - Sierra Chart Boards This thread Refback 07-26-2007 08:42 AM
how to plot standard deviation of the vwap - Sierra Chart Boards This thread Refback 07-26-2007 08:28 AM
Traders Laboratory - forumdisplay This thread Refback 07-23-2007 11:45 PM


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread