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.

agon

Volume Splitter

Recommended Posts

Results from testing the four indicators created on this thread:

1) phall permalink #73 p. 8

2) swansjr permalink #87 p. 9

3) Blowfish #1 permalink #91 p. 10

4) Blowfish #2 permalink #120 p. 12

 

So, what do these results tell us?

 

When I took the Blowfish #2 code and made all the lines into histograms, it looked really different. Even the values were different. Not sure what that's about.

 

Divergences on Blowfish #1 look very nice, actually.

 

Code for phall maybe TOO smoothe?

 

Code for swansjr maybe TOO choppy?

 

BTW, I haven't made any changes to the code as posted. I wouldn't know what to change anyway, since I don't understand what these indicators are actually looking at.

5aa70ed374e16_ES1mBlowfishcode1and2.thumb.png.2b1df02dc2e0a518c21894fa76a07976.png

5aa70ed37d4b9_ES1mphallandswansjr.thumb.png.703cd8c47df4459cca75fbc5d8f22d14.png

5aa70ed3857ce_ES377tickBlowfishcode1and2code2ashistogram.thumb.png.78be1f83ff7f689ec61771ef0aba0925.png

5aa70ed395652_ES377tickBlowfishcode1and2.thumb.png.8d1317d64a3a95b3be74497b15fa99cb.png

5aa70ed3a09a9_ES377tickphallandswansjr.thumb.png.e8e6daf020cfe74c1fc7ca394a0934d0.png

5aa70ed3a902a_ES4181volumeBlowfishcode1and2.thumb.png.da1b9b2d688fcba504e3537cb3265779.png

5aa70ed3b1025_ES4181volumephallandswansjr.thumb.png.be7402340b44ebc7e41d024b8667d2e1.png

Share this post


Link to post
Share on other sites

Try plotting the second set of code I posted as OHLC bars Tasuki. I wouldn't bother with a block filter on that at all. Ideally plot it from session open....it attempts to show the absolute 'order flow' for the day. As I mentioned before I think the >= sign that compares with the block size is probably the wrong way round. If you are including all order flow that shouldn't matter.

Share this post


Link to post
Share on other sites

Hi

got a little more time to work on this. my last post was a paste of the two pieces i'd seen in previous posts. after running it for a while, i wasn't happy with the way the TRIX was over smoothing it.

 

i found that plotting the running line of the net shares caused the referencing to be all screwy. So i change it to summing everything over a fixed window and plot a smoothed version of it. Then i calculated the momentum of that and plot that also. Note: you need to let the indicator run for at least 1/2 of the total set Cumulative length before it means anything.

 

Setting the minlot to 99 and letting it run on a 3 min chart seemed to get close; i can see when the big boys start accumulating/distributing. the momentum line helps alot also to give you some warning that a change is coming.

 

As with all these averaged indicators, alot of work needs to be done picking the averaging lengths for the time frame to get what you want. Any feedback on testing different settings would be great.

 

Anyway, here's the code; if you could test it a bit and let me know what you find out that'd be great.

 

ALSO, PLEASE VOTE AT TRADESTATION FOR THE T&S data in Easylanguage. THANKS

 

phall

 

Code: Sorry about the formatting:

 

 

{phall 5/12, Volume Splitter}

 

Inputs: MinLotSize(99),

MaxLotSize(999),

CumulativeLength(50),

CumulativeAvgLength(20),

MomLength(2),

MomSmoothLength(3);

 

 

Var: intrabarpersist LTicks(0);

Var: intrabarpersist TSize(0);

Var: intrabarpersist UpSum(0);

Var: intrabarpersist DnSum(0);

Var: intrabarpersist CumSum(0);

 

Vars:

Deltacum(0),

CumOverLength(0),

Moment(0);

 

if LastBarOnChart then

Begin

 

TSize = Ticks - LTicks;

LTicks = Ticks;

If TSize >= MinLotSize and TSize <= MaxLotSize then

Begin

if Close = CurrentBid then DnSum = DnSum + TSize;

if Close = CurrentAsk then UpSum = UpSum + TSize;

End;

 

if BarStatus(1) = 2 then {Bar Close}

begin

CumSum = CumSum[1] + UpSum - DnSum ;

LTicks = 0; UpSum = 0; DnSum = 0;

End;

End;

 

{difference in contracts from last bar}

DeltaCum=Cumsum-Cumsum[1];

 

{calculated over fixed window, this is running total of net contracts in window length }

CumOverLength=Xaverage(Summation(Deltacum,CumulativeLength),CumulativeAvgLength);

 

{smoothed momentum line of the net contracts}

Moment=xaverage((Cumoverlength-CumoverLength[momlength]),momsmoothlength);

 

{Plots both the Total, Momentum of total, and Net change per bar}

Plot1(CumOverLength, "Cumulative"); {this is the main indicator showing running total}

 

Plot2(Moment*5,"Mom"); {this is the momentum line of main indicator; may need to adjust the "5" scaling factor}

 

Plot3(DeltaCum,"Cum. Net Chg"); {this is good to plot as histo so you can see net change every bar}

Share this post


Link to post
Share on other sites

hi

the ehlers instantaneous trendline in place of the EMA will speed it up alot

also, after looking at some data, the CumulativeLength might be better set to 20, Cumavglength to 10

 

phall

Edited by phall

Share this post


Link to post
Share on other sites
Try plotting the second set of code I posted as OHLC bars Tasuki. I wouldn't bother with a block filter on that at all. Ideally plot it from session open....it attempts to show the absolute 'order flow' for the day. As I mentioned before I think the >= sign that compares with the block size is probably the wrong way round. If you are including all order flow that shouldn't matter.

 

Blowfish,

 

1) So, do I just set the blockfilter to 0 in the inputs of the indicator?

 

2) Is this the line in your code that you're referring to regarding the sign being the wrong way around?:

 

if absvalue(MyVol-VolTmp) <= LargeBlockFilter then begin

 

This is the way it appears in my code, but it's got the less than or equals,

not the greater than or equals. Maybe I'm looking at the wrong spot in the

code? Please explain, and thanks!

 

Tasuki

Share this post


Link to post
Share on other sites

The new Blowfish indicator rocks! check out this divergence today on the es 1min!

 

dumb money is the bottom thinking we were going to go higher into hourly resistance and smart money is the top selling hard after dumb money bought a 1 min pull back.

 

granted I started plotting it half way through the day it still worked fine.

 

 

pretty sexy stuff. keep up the good work!

Share this post


Link to post
Share on other sites

Check out the divergence today on the 1 min es! big money is top dumb money is bottom!

 

Smartmoney was selling into 1 hour resistance while dumb money was buying a 1min pull back! check out the sell off after they bought blowing through dumb money's stops!

 

pretty sexy stuff! keep up the good work!

5aa70ed446299_VolSplitter.jpg.2704b7cfaf3ab3f19460009368ba5de9.jpg

Edited by slytrader
new to posting :-D

Share this post


Link to post
Share on other sites

Glad you like it. I have to say it's a while since I have had it on a chart but was rather surprised by how revealing it was when I ran it yesterday. I do have an issue with it intellectually and that is the assumption that informed traders ('smart money') will buy or sell aggressively (hit the bid or ask). That's just not the case for certain types of traders or under certain market conditions. Having said that it does seem to be a decent guage of order flow.

Share this post


Link to post
Share on other sites
I do have an issue with it intellectually and that is the assumption that informed traders ('smart money') will buy or sell aggressively (hit the bid or ask).

 

I thought so too, but then I realized that it's actually might be better to be a market taker when you are a large directional trader since you have the ability to change a price. For example, let's say the best bid is 9 and best ask is 10. There are 200 contracts bid on 9 and 200 contracts offered on 10. The large trader wants to buy. The buyer has two options:

1) Place limit order on bid

2) Hit the ask with a market order

 

Let's go through both scenarios:

1) You join the bid. Now there need to be 400 contracts traded on the bid to fill your entire order. There are two problems with this:

a) You don't get your entire order filled because less than 400 contracts trade (which is bad).

b) You do get your entire order filled but the whole bid would have to be taken out unless another large trader joins after you on the bid. This means the price changes to bid 8, ask 9. Your got filled on 9 which would have been the same if you had waited for the price to change down and then hit the ask. But you took the risk of not getting executed by using that limit order.

 

2) You hit the offer and it's likely you take out the ask doing that. So the new price is now 11 bid, 11 ask. Your order was filled at 10. So you have effectively bought the bid of the new price. But your execution was guaranteed.

 

I think scenario 2 is more favorable if you are a large directiona trader since in fact you can take out an entire price with your market order. Another problem with limit order is that you might not want to show your entire size to avoid front runners, but if you don't you might not get filled. But even if you do get filled, you always want order flow to change immediately after you get filled. What I mean by that is you want your bid to get filled by sell market orders, but as soon as you get filled, you want to see buy market orders to make price go up and not put you in a losing position. If you use a market order instead, you get filled immediately. Yes, your order shows up on the time & sales. But you don't care. You're already in. If anything, it's a good thing that you order is visible on the tape because you are making other traders that watch indicators like those posted in this thread follow you, pushing price in the direction you want it to go.

 

Of course, as with everything in trading it's never not clear cut and it depends on your strategy, but I just wanted to point out that market orders do have advantages, especially if you are a big trader.

Share this post


Link to post
Share on other sites

AgeKay and Blowfish – thanks. For the reasons you both gave (and a couple other reasons too) I decided to go /stay with an ‘unfiltered’ flow indicator and learn when (and when not) to use it and when to go with it and when to fade it... I found that with all of these versions of ‘money flow’ indicators, learning when to use them is more important than how.

Share this post


Link to post
Share on other sites

Most surely there are times that it will be true others not. Different participants have widely different agendas and modus operandi. Hell, some participants are not even profit motivated (not as you or I would think of 'profit'). I would recommend any one who is interested to check out a decent book on Market Microstructure Harris writes 650 odd pages on the subject it is quite a deep and involved subject and hard to do justice to in a couple of forum posts. :) Really we would need to go through each type of participant and look at how they operate.

 

Back to the indicator (the 2nd one which is going to need a name I guess....how about net order flow? cumulative net order flow is a bit of a mouthful) again, today, it has given some pretty good insight to the days goings on. I am tempted to incorporate it into my trading. Trouble is to do any testing is going to take an eternity as it only runs live. I'd also like to look at longer accumulations (like a week) of data too. Again a pain really with the real time restriction. It's about time charting applications save order book information and generated update ticks on all data streams.

Share this post


Link to post
Share on other sites
AgeKay and Blowfish – thanks. For the reasons you both gave (and a couple other reasons too) I decided to go /stay with an ‘unfiltered’ flow indicator and learn when (and when not) to use it and when to go with it and when to fade it... I found that with all of these versions of ‘money flow’ indicators, learning when to use them is more important than how.

 

Good for you :)

....

Share this post


Link to post
Share on other sites

Blowfish,

 

Your indicator seems interesting, and I would like to test it for a while. Is there anyone here that can code it for ninja trader? I would attempt to myself, but I know very little about programming.

Thanks

Share this post


Link to post
Share on other sites

Two charts attached.

Both are ES 233 tick. Both have two indicators, the Blowfish indicator #2 and also the modification suggested by bakrob99 which I'm calling Blow3. He suggested the following:

 

if absvalue(MyVol-VolTmp) >= LargeBlockFilter then begin

 

The original had a <=

 

I'm not sure what this does, but it makes it so that the indicator looks the same whether you keep the default value of 100 for "LargeBlockFilter" in Inputs, or whether you change it from 100 to 10. Maybe this change just disables the LargeBlockFilter?

 

That doesn't really help me use the indicator, however. In fact, I have no idea what it's actually doing. Can someone explain in plain English what this indicator does?

Secondarily, how would you use it to trade?

 

You'll notice that the lower indicator, the Blow2 (Blowfish's original code from p.12, permalink #120) does come out differently when you change the LargeBlockFilter from 100 to 10. What does this LargeBlockFilter actually filter? Is it filtering OUT the large blocks of trades, or filtering them IN? If you have it set to 100, does the indicator now INCLUDE or EXCLUDE large blocks?

Again, how does this help you understand the market, and more importantly, how can you use this to help you trade?

5aa70ed51c345_ES233TBlow2Blow3LBF10.thumb.png.ae17000d6dcbb295b0d1b5c4cd745e8f.png

5aa70ed526326_ES233TBlow2Blow3LBF100.thumb.png.c2f45deb67c0051a0c0dc5c35966231c.png

Share this post


Link to post
Share on other sites

<= means to count the delta of trades smaller than LargeBlockFilter (i.e. "small trades")

>= means to count the delta of trades larger than LargeBlockFilter (i.e. "big trades")

 

Tasuki, you should definitely try to understand what this indicator means. Otherwise, it's just one more "magic" indicator that will never make you money.

Share this post


Link to post
Share on other sites

Never ceases to amaze me that I get more good stuff from TL than anywhere else. :) I went to their website and watched their "Alahas" indicator. Did anyone notice that this and their SD's look very similar to trading with market stats that JPERL did with VWAP and SD's?

Share this post


Link to post
Share on other sites

AgeKay, you managed to quote me on something I didn't say, and I don't think that's correct. The way Blowfish's code is written it would appear that if you use the greater than sign....in this code here:

 

if absvalue(MyVol-VolTmp) >= LargeBlockFilter then begin

 

then it appears that you must turn OFF the LargeBlockFilter, because the indicator looks identical when you use a block filter of 10 or 100.

 

However, if you use the less than sign, like this:

 

if absvalue(MyVol-VolTmp) <= LargeBlockFilter then begin

 

then you find that the indicator looks different when you use a block filter of 10 vs. 100.

I'm assuming that this means that the block filter is ON when your code has the "less than or equal" sign in it.

 

Have I got this right?

Share this post


Link to post
Share on other sites

Sorry, Tasuki, I didn't mean to put it in quotes. The text in the code was supposed to be my reply to your question what the <= and >= signs in BlowFish's code mean.

 

So:

 

<= means to count the delta of trades smaller than LargeBlockFilter (i.e. "small trades")

>= means to count the delta of trades larger than LargeBlockFilter (i.e. "big trades")

 

And the text below the quote was just my general comment also directed to you.

Share this post


Link to post
Share on other sites

Tasuki, AgeKey

 

Yesterday I looked a little more closely into the code and decided to change the blocksizefilter to have an "include" filter and an "Exclude" filter.

 

Example1: So now you can have the code run on JUST small size blocks by setting the include filter to 0 and the exclude filter to say 49 on the ES. This would have the effect of tracking trades with sizes between 1 and 49 only. No big size lots. Just the small ones.

 

Example2: You can also set it to Include size say 50 (for 50 and above trades) and Exclude Size 9999 to keep all the large ones. This would have the effect of tracking trades for only the large lot sizes.

 

It's simple to make these changes:

 

Replace:

LargeBlockFilter(0),

with:

IncludeSizeGT(0),

ExcludeSizeLT(9999),

 

This Line:

if absvalue(MyVol-VolTmp) >= LargeBlockFilter then begin

Becomes:

if absvalue(MyVol-VolTmp) >= IncludeSizeGT

and absvalue(MyVol-VolTmp) <= ExcludeSizeLT then begin

 

Hope this clarifies things a bit.l

 

Oh ... one other thing I did which Might help keep track of multiple settings for this indicator:

 

Add as the very first input the following:

Desc("AddText"),

 

Then when you are setting the inputs say for Small Lot Sizes:

Change the Desc input to "Small Lots",

 

This will now display the text "Small Lots" on your subgraph indicator description line so you can easily know what you are tracking.

Edited by bakrob99

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.


  • Topics

  • Posts

    • Date: 25th April 2024. Investors Monitor a Potential Japanese Intervention, and upcoming Tech Earnings. Meta stocks top earnings expectations, but revenue guidance for the next 6 months triggers significant selloff. Meta stocks decline 15.00% and the Magnificent Seven also trade lower. Japanese Authorities are on watch and most market experts predict the Japanese Federal Government will intervene once again. The Japanese Yen is the day’s worst performing currency while the Australian Dollar continues to top the charts. The US Dollar trades 0.10% lower, but this afternoon’s performance is likely to be dependent on the US GDP. USA100 – Meta Stocks Fall 15% On the Next 6-Months Guidance The NASDAQ has declined 1.51% over the past 24 hours, unable to maintain momentum from Monday and Tuesday. Technical analysts advise the decline is partially simply a break in the bullish momentum and the asset continues to follow a bullish correction pattern. However, if the decline continues throughout the day, the retracement scenario becomes a lesser possibility. In terms of indications and technical analysis, most oscillators, and momentum-based signals point to a downward price movement. The USA100 trades below the 75-Bar EMA, below the VWAP and the RSI hovers above 40.00. All these factors point towards a bearish trend. The bearish signals are also likely to strengthen if the price declines below $17,295.11. The stock which is experiencing considerably large volatility is Meta which has fallen more than 15.00%. The past quarter’s earnings beat expectations and according to economists, remain stable and strong. Earnings Per Share beat expectations by 8.10% and revenue was as expected. However, company expenses significantly rose in the past quarter and the guidance for the second half of the year is lower than previous expectations. These two factors have caused investors to consider selling their shares and cashing in their profits. Meta’s decline is one of the main causes for the USA100’s bearish trend. CFRA Senior Analyst, Angelo Zino, advises the selloff may be a slight over reaction based on earnings data. If Meta stocks rise again, investors can start to evaluate a possible upward correction. However, a concern for investors is that more and more companies are indicating caution for the second half of the year. The price movements will largely now depend on Microsoft and Alphabet earnings tonight after market close. Microsoft is the most influential stock for the NASDAQ and Alphabet is the third. The two make up 14.25% of the overall index. If the two companies also witness their stocks decline after the earnings reports, the USA100 may struggle to gain upward momentum. EURJPY – Will Japan Intervene Again? In the currency market, the Japanese Yen remains within the spotlight as investors believe the Japanese Federal Government is likely to again intervene. The Federal Government has previously intervened in the past 12 months which caused a sharp rise in the Yen before again declining. The government opted for this option in an attempt to hinder a further decline. Volatility within the Japanese Yen will also depend on today’s US GDP reading and tomorrow’s Core PCE Price Index. However, investors will more importantly pay close attention to the Bank of Japan’s monetary policy. Investors will be keen to see if the central bank believes it is appropriate to again hike in 2024 as well as comment regarding inflation and the economy. In terms of technical analysis, breakout levels can be considered as areas where the exchange rate may retrace or correct. Breakout levels can be seen at 166.656 and 166.333. However, the only indicators pointing to a decline are the RSI and similar oscillators which advise the price is at risk of being “overbought”. Always trade with strict risk management. Your capital is the single most important aspect of your trading business. Please note that times displayed based on local time zone and are from time of writing this report. Click HERE to access the full HFM Economic calendar. Want to learn to trade and analyse the markets? Join our webinars and get analysis and trading ideas combined with better understanding on how markets work. Click HERE to register for FREE! Click HERE to READ more Market news. Michalis Efthymiou Market Analyst HFMarkets Disclaimer: This material is provided as a general marketing communication for information purposes only and does not constitute an independent investment research. Nothing in this communication contains, or should be considered as containing, an investment advice or an investment recommendation or a solicitation for the purpose of buying or selling of any financial instrument. All information provided is gathered from reputable sources and any information containing an indication of past performance is not a guarantee or reliable indicator of future performance. Users acknowledge that any investment in FX and CFDs products is characterized by a certain degree of uncertainty and that any investment of this nature involves a high level of risk for which the users are solely responsible and liable. We assume no liability for any loss arising from any investment made based on the information provided in this communication. This communication must not be reproduced or further distributed without our prior written permission.
    • $ALVR AlloVir stock bottom breakout watch, huge upside gap, https://stockconsultant.com/?ALVR
    • $DIS Disney stock attempting to move higher off the 112.79 triple support area, https://stockconsultant.com/?DIS
    • $ADCT Adc Therapeutics stock flat top breakout watch above 5.31, https://stockconsultant.com/?ADCT
    • $CXAI CXApp stock local support and resistance areas at 2.78, 3.52 and 5.19, https://stockconsultant.com/?CXAI
×
×
  • Create New...

Important Information

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