Jump to content

Welcome to the new Traders Laboratory! Please bear with us as we finish the migration over the next few days. If you find any issues, want to leave feedback, get in touch with us, or offer suggestions please post to the Support forum here.

  • Welcome Guests

    Welcome. You are currently viewing the forum as a guest which does not give you access to all the great features at Traders Laboratory such as interacting with members, access to all forums, downloading attachments, and eligibility to win free giveaways. Registration is fast, simple and absolutely free. Create a FREE Traders Laboratory account here.

jperl

Trading with Market Statistics XI. HUP

Recommended Posts

Hi Jerry

Thanks a lot for your answer.

 

Main reason for my previous question comes from what you wrote few pages back at this thread (as an answer to Trader333)

 

“Also think about what you would have done if the trade at the VWAP had not gone your way. Would you have exited the trade at the PVP or done something else?”

 

Trader333 answered:

I would have exited at either the PVP line or 1st Standard Deviation away from entry whichever was nearer at the time.

 

And you wrote:

That is what most traders would do and in my opinion leads to a slow bleed of your capital

 

By this answer I assume you would have stayed in the trade although market conditions changed. (?)

Can you please advise what would you have done?

 

Thanks!

 

moon

 

The answer moon depends on several factors: a)what my position size was at the initial entry, b) what my profits look like up to that point, c)how fast the market is moving. So there is no unique answer.

So let's assume this is my first trade of the day, and I enter light (well below my contract limit) and the market is moving slowly. I would have most likely doubled up on my contracts at the 1st SD away from the entry and tried to exit the trade close to break even.

If the market is moving fast (fast and slow are of course about individual perception), I might have reversed the trade at the 1SD away from entry and doubled up on the number of contracts.

If instead I was close to my profit target for the day from previous trades, I might have simply exited the trade at the PVP.

Share this post


Link to post
Share on other sites

Jerry, please for give me for nagging…

 

If price goes to the +sd1, we are actually at what you called DMZ (The area where the price is near the PVP and the PVP is sandwiched between the VWAP and the SD)

Also, at this point the skew is negative (VWAP<PVP) and trend is bullish (Price>VWAP) – so why: “I would have most likely doubled up on my contracts at the 1st SD away from the entry and tried to exit the trade close to break even.” ?

The +sd1 doesn’t seem to be a good place to enter short (at slow or fast market)

Doesn’t it make more sense to admit the loss and look for another trade where chances are in our favor?

 

With a lot of appreciation,

 

moon

Share this post


Link to post
Share on other sites

Moon, I think this method presented by Jerry here is a good hint, but like any other method it is not a miracle. In fact price often bounces from or crosses VWAP and SD's in a "wrong" direction, no matter what Skew bias is. What seems to be important is also the slope of VWAP (i.e. the strenght of daily trend), the real statistical Skew which I wrote about a few posts above, S/R areas (or HUP's), etc. I believe that one must able to judge price action near possible entry/exit points as well as the "big picture". This might give him the answer whether to scale-in or exit.

 

Just my guess, Jerry please correct me if I am wrong.

Share this post


Link to post
Share on other sites
Jerry, please for give me for nagging…

 

If price goes to the +sd1, we are actually at what you called DMZ (The area where the price is near the PVP and the PVP is sandwiched between the VWAP and the SD)

Also, at this point the skew is negative (VWAP<PVP) and trend is bullish (Price>VWAP) – so why: “I would have most likely doubled up on my contracts at the 1st SD away from the entry and tried to exit the trade close to break even.” ?

The +sd1 doesn’t seem to be a good place to enter short (at slow or fast market)

Doesn’t it make more sense to admit the loss and look for another trade where chances are in our favor?

 

With a lot of appreciation,

 

moon

 

You are correct moon. The +sd1 price is not a good place to enter a short. If I were not already in a trade, I would not short at that point. However, given the circumstances you outlined, with a trade in progress, you have three choices: a) exit the trade at +sd1 and accept the loss b)scale in and try to exit the trade at break even or c)reverse the trade at +sd1 with possible increase in position size. A good trader should be willing to consider any of these options at any time. A new trader would only consider option a) all the time. My point is, that new traders are limiting their capabilities for trade management by only considering option a). When you allow yourself the option to consider options b) and c) as well, you will find that a whole new vista of trading is open to you.

Share this post


Link to post
Share on other sites
Moon, I think this method presented by Jerry here is a good hint, but like any other method it is not a miracle. In fact price often bounces from or crosses VWAP and SD's in a "wrong" direction, no matter what Skew bias is. What seems to be important is also the slope of VWAP (i.e. the strenght of daily trend), the real statistical Skew which I wrote about a few posts above, S/R areas (or HUP's), etc. I believe that one must able to judge price action near possible entry/exit points as well as the "big picture". This might give him the answer whether to scale-in or exit.

 

Just my guess, Jerry please correct me if I am wrong.

 

No you are not wrong Head. In fact you have some good ideas, especially about the skew. I think you should start a new thread on trading with the skew. I have some ideas about this that might be useful

Share this post


Link to post
Share on other sites
No you are not wrong Head. In fact you have some good ideas, especially about the skew. I think you should start a new thread on trading with the skew. I have some ideas about this that might be useful
I am sorry but I will not start a new thread. Simply because I have nothing to offer or to contribute with. Yes, I added the Skew(3CM). Yes, I think it filtered away more bad trades than the good ones. But that is all, and all this was already said here. I tried to paper trade a system based on your threads on ES and I was not satisfied with results. I began to watch hourly ROC of VWAP and used it as another filter. I ended up with filtering away the most of trade opportunities and started to be frustrated, sitting in front of the screen and doing nothing.

While I think that VWAP and SD's are good entry/exit points, I dont really know how to trade with skew. And I dont even know if it is a good idea to trade with it. Do skewed distributions tend to come to the balanced ones? I dont know.

And I apologize for a sort of hijacking your thread for several pages. I posted here as a reaction to jgotchev who mentioned the central moment here. It wasnt intended to elaborate on the skew over several pages.

 

If you want to start a new thread about Trading With Skew, feel free to use my ideas, posts or charts, but I dont feel competent to start the thread myself, because I kind of lost the track. But I promise I will not mess up this thread again :)

Share this post


Link to post
Share on other sites

I think skewed distributions do balance but it seems to me that is usually by building a new base rather than returning to the old one. That is not to say that they can not return to the previous PVP after balancing for a while.

 

EDIT: I don't think you 'messed up the thread' at all. Maybe better places to have discussed things (and I am to blame there too) but I think you brought something new and interesting to the table. The issue is how to integrate the information.

Share this post


Link to post
Share on other sites

In http://en.wikipedia.org/wiki/Skewness there are two calculations as a measure of skewness suggested by Pearson :

 

(mean - mode) / standard deviation

3 (mean - median) / standard deviation

 

the first one is using with PVP I was using till now, the second approximation is using the median instead of PVP. I switch the calculation using median and seems it provides similar qualities as the 3CM method. The Skew does not change abruptly as PVP change but change gradually along the day, this provides a nice head up when PVP is about to jump, the skew slope is a good proxy for the market direction and in some cases provides nice heads up that a change is on the way.

 

The attached picture is yesterday ES action, in the first pane the purple line around VWAP (blue) is VWAP+Skew*SD, The yellow is PVP, the second pane displays the actual skew

ES-Sep08.jpg.5704686d3f707b172137fe03089e8aa3.jpg

Share this post


Link to post
Share on other sites
In http://en.wikipedia.org/wiki/Skewness there are two calculations as a measure of skewness suggested by Pearson :

 

(mean - mode) / standard deviation

3 (mean - median) / standard deviation

 

the first one is using with PVP I was using till now, the second approximation is using the median instead of PVP. I switch the calculation using median and seems it provides similar qualities as the 3CM method. The Skew does not change abruptly as PVP change but change gradually along the day, this provides a nice head up when PVP is about to jump, the skew slope is a good proxy for the market direction and in some cases provides nice heads up that a change is on the way.

 

The attached picture is yesterday ES action, in the first pane the purple line around VWAP (blue) is VWAP+Skew*SD, The yellow is PVP, the second pane displays the actual skew

 

Good observation Karish. The second computation may be simpler to do for those who can't use the exact definition of the moment.

Share this post


Link to post
Share on other sites
In http://en.wikipedia.org/wiki/Skewness there are two calculations as a measure of skewness suggested by Pearson :

 

(mean - mode) / standard deviation

3 (mean - median) / standard deviation

 

the first one is using with PVP I was using till now, the second approximation is using the median instead of PVP. I switch the calculation using median and seems it provides similar qualities as the 3CM method. The Skew does not change abruptly as PVP change but change gradually along the day, this provides a nice head up when PVP is about to jump, the skew slope is a good proxy for the market direction and in some cases provides nice heads up that a change is on the way.

 

The attached picture is yesterday ES action, in the first pane the purple line around VWAP (blue) is VWAP+Skew*SD, The yellow is PVP, the second pane displays the actual skew

 

 

Karish.

I'm trying to plot this in C#. Is there a simple way of calculating the median of the price distribution? I'm thinking of creating a list double that will insert each price point repetitively until all volume is accounted for, and then sort and figure out the median. This seems tedious, is there a simpler way?

 

 

thanks

Share this post


Link to post
Share on other sites
Karish.

I'm trying to plot this in C#. Is there a simple way of calculating the median of the price distribution? I'm thinking of creating a list double that will insert each price point repetitively until all volume is accounted for, and then sort and figure out the median. This seems tedious, is there a simpler way?

 

 

thanks

 

Median is simply the mid point L+ (H-L)/2

You are thinking of mode (or PVP) here you need to keep an array with each element representing a price level as you describe.

Share this post


Link to post
Share on other sites
Median is simply the mid point L+ (H-L)/2

You are thinking of mode (or PVP) here you need to keep an array with each element representing a price level as you describe.

 

This would be correct only if the number of trades at each price were identical, which is usually not the case. To determine the median, you have to order all the trades from low to high, add up the total number, then find the price where the half way point is located.

 

Example: 1,2,2,2,2,2,3,4,5. There are nine trades between 1 and 5. Half way point is 2, not 3.

Share this post


Link to post
Share on other sites
This would be correct only if the number of trades at each price were identical, which is usually not the case. To determine the median, you have to order all the trades from low to high, add up the total number, then find the price where the half way point is located.

 

Example: 1,2,2,2,2,2,3,4,5. There are nine trades between 1 and 5. Half way point is 2, not 3.

Just to complete your post to BlowFish:

 

If we are talking about median of the volume distribution function, you are not concerned about single trades, but about volume at each price. So you take that array that blowfish was talking about and order all its elements, i.e. volumes at each price.

Share this post


Link to post
Share on other sites
This would be correct only if the number of trades at each price were identical, which is usually not the case. To determine the median, you have to order all the trades from low to high, add up the total number, then find the price where the half way point is located.

 

Example: 1,2,2,2,2,2,3,4,5. There are nine trades between 1 and 5. Half way point is 2, not 3.

 

I was afraid of that, but just to make sure, a contract that trades 100000 units and for example each trade was 10000 units at each price point. Then the Median would be (price range $1 - $10) the middle value of 1,1,1,1...(10000 times),2,2,2,....(10000times), .........,10,10,10,10 (10000 times)?

 

this example is easy since all volumes are identical but when each volume at price is different, the list gets huge if I have this correct?

 

thanks

Share this post


Link to post
Share on other sites

For computation of mode, mean or median of the volume distribution function you need to keep an array with volume at each price.

Such an array needs to have exactly that number of elements as how many different prices are there in evaluated period (in this case in one day). So if tick size is 0.25 and current daily range is 10 you need to maintain an array of 41 elements. You dont need to care about concrete trades.

To calculate median of such an array you need to order its elements by size and find the middle one in this sequence. If there is an even number of them you can take any number between and including the middle two. Search Wikipedia for median.

Share this post


Link to post
Share on other sites
For computation of mode, mean or median of the volume distribution function you need to keep an array with volume at each price.

Such an array needs to have exactly that number of elements as how many different prices are there in evaluated period (in this case in one day). So if tick size is 0.25 and current daily range is 10 you need to maintain an array of 41 elements. You dont need to care about concrete trades.

To calculate median of such an array you need to order its elements by size and find the middle one in this sequence. If there is an even number of them you can take any number between and including the middle two. Search Wikipedia for median.

 

Ahh, the missing link being sort by size and not by price. I knew there was a simpler way, just couldn't get my head around it. So effectively it is the middle value of the volume numbers in a sorted list. Once found, the price at that volume is noted. I kept thinking of median in terms of price. Thanks.

Share this post


Link to post
Share on other sites
Ahh, the missing link being sort by size and not by price. I knew there was a simpler way, just couldn't get my head around it. So effectively it is the middle value of the volume numbers in a sorted list. Once found, the price at that volume is noted. I kept thinking of median in terms of price. Thanks.
Exactly. (The volume distribution function could be called Distribution of volume in sample of prices, to make it more obvious.)

Share this post


Link to post
Share on other sites

Jerry, tonight I am thinking of determining price levels where to act. That is key price levels where one can expect increased support and resistance. That is HUP's. The problem I cannot figure out is the scale I should focus at. You start computation at the session beginning, but in another thread you also say that you can start it later when scalping. Sounds logical. Your indicator pinpoints potential S/R levels within given time frame (or interval). Now if you have a fixed computation start the time frame increases with new data added to the computation.

Now take Fibonacci, another way to pinpoint potential S/R levels. It behaves similarly. Lets say, in downtrend, you start on high so you have fixed beginning of Fibo range. As you add new data the range extends and you get new probable retracement levels. Within this major trend there is a lot of up and down swings and you can use Fibo at each of them, too. That is similar with using long term and short term HUP's. It is just the market fractality.

Now my questions are:

 

1. Have you ever though about possible connections of market statistics and Fibonacci? To me it looks like 38.2 and 61.8 % levels could mark the first standard deviations in some special case of distribution and perhaps also a special case of data sample. (Might be complete off, of course, but it just came on my mind...)

 

2. With regard to above, have you ever thought about a logical placement of VWAP computation other than the beginning of a session? Such as major or intermediate swing high or low, or a beginning or end of trading range? If you did, what conclusions did you come to? Or how to trail the beginning of computation to obtain potential S/R levels of comparable importance, not with importance increasing with new data added?

 

3. What do you think of TRM (Trade Risk Management, that's a name of company) method based on Hurst analysis, which is basically a spectral analysis of price development, finding dominant frequencies and applying SD's as well?

 

I think that all these methods must have something in common, some ultimate root. I guess one doesn't need to find the ultimate theory (the holy grail?) to be able to trade, but from (almost) purely scientific interest I wonder if you ever thought of this.

And if not, at least please try to answer the question nr. 2, as it has more practical meaning :)

Share this post


Link to post
Share on other sites

Now take Fibonacci, another way to pinpoint potential S/R levels. It behaves similarly. Lets say, in downtrend, you start on high so you have fixed beginning of Fibo range. As you add new data the range extends and you get new probable retracement levels. Within this major trend there is a lot of up and down swings and you can use Fibo at each of them, too. That is similar with using long term and short term HUP's. It is just the market fractality.

 

and

1. Have you ever though about possible connections of market statistics and Fibonacci? To me it looks like 38.2 and 61.8 % levels could mark the first standard deviations in some special case of distribution and perhaps also a special case of data sample.

 

 

The problem with using Fibonacci levels as with most other technical analysis is that there is a builit in time dependence of unknown structure.

Using your example of downtrend, if two traders, one using a 1 minute chart to trade from, the other using a 3 min chart to trade from were to determine fibonacci levels starting at the same high point, they would not agree as to where to place the end of the range for computing the levels.

As a consequence they would not agree as to where the retracement levels would occur.

Now compare that to the same two traders using market statistics starting at the same time. They would both agree what the VWAP is and the value of the standard deviation, even though they were using different chart times to trade from.

 

2. With regard to above, have you ever thought about a logical placement of VWAP computation other than the beginning of a session? Such as major or intermediate swing high or low, or a beginning or end of trading range? If you did, what conclusions did you come to? Or how to trail the beginning of computation to obtain potential S/R levels of comparable importance, not with importance increasing with new data added?

This has been discussed in great detail by others. See the thread

[thread=2859]Playing with the dynamic VWAPS open research[/thread]

 

3. What do you think of TRM (Trade Risk Management, that's a name of company) method based on Hurst analysis, which is basically a spectral analysis of price development, finding dominant frequencies and applying SD's as well?

 

Hurst analysis is a way to analyze a time series data for fractal components. This has been discussed in some detail by Mandelbrot. I have only taken a cursory look at this so I can't really comment about how useful it might be. From what I understand there is considerable disagreement as to how to compute the Hurst exponent.

 

I think that all these methods must have something in common, some ultimate root. I guess one doesn't need to find the ultimate theory (the holy grail?) to be able to trade, but from (almost) purely scientific interest I wonder if you ever thought of this.

 

Whether there is a holy grail or not isn't important. More important is learning how to trade.

Share this post


Link to post
Share on other sites

Hi Jerry,

 

I want to thank you for your post, indeed i took valuable information from your videos and commentary. I was curious as to whether your videos was recorded during a live market or during market replay sessions.

 

thx

Share this post


Link to post
Share on other sites
Hi Jerry,

 

I want to thank you for your post, indeed i took valuable information from your videos and commentary. I was curious as to whether your videos was recorded during a live market or during market replay sessions.

 

thx

 

Most of the videos were recorded during live sessions although in some cases, I had to go back and edit them for pedogogical and time constraints. A few were playbacks that I did in order to demonstrate some particular principle.

Share this post


Link to post
Share on other sites

Wow, Gone thru these videos and all the threads several times. I am blown away. I have been trading for a long time now but learn something new everyday. I defintely am a newbie when it comes to this approach though. Jperl I think your jaw would drop the way I am trading your method. I have a tendency to fade alot and I have used to bands mainly for that hence I need to go thru the videos again to learn to take the moves thru the first standard deviation when skew is positive.

Share this post


Link to post
Share on other sites
Jperl do you know if ensign(which I am using and you should get a kickback for) can place the skew histogram on the chart like Karish has done?

 

It's possible to do this in Ensign, but it is not a standard study. You would have to write your own ESPL code to do it.

Your other choice is to ask Howard Arrington (Ensign software developer) to offer this as a study.

Share this post


Link to post
Share on other sites

Thanks for sharing your method with me. I faded SPY on the close at 91.15 on - 1sd from pull up from -2sd

plus market on close imbalance was a sell

plus vwap under POV plus price was under vwap.

 

The price around vwap is tough for me I want to buy at -2sd no matter where price is relative to VWAP and sell at +2sd. I am working on this. I covered my SPY at 90.50.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.