Austin, TX
Experience: Advanced
Platform: TradeStation
Trading: Futures
Posts: 839 since Mar 2011
Thanks Given: 124
Thanks Received: 704
|
Well, since all I got was crickets....I crafted my own.
Here it is
Inputs: SFColor(Red), Pivotline(Blue),GraphicAmplifier(1000), PivotLineValue(1);
Variables: SlippageFactor(0), moves(0), orders(o);
moves = (absvalue(high-open) + absvalue(high-low) + Absvalue(close-low));
orders = (Upticks+downticks);
SlippageFactor = (moves/orders)*GraphicAmplifier;
SetPlotColor(1,SFColor);
{SetPlotColor(2,Pivotline);}
plot1( SlippageFactor, "Slippage" ) ;
Plot2( PivotLineValue, "Pivotline" ) ;
Feel free to check it out. You can mess around with the GraphicAmplifier value to draw out spikes and lows to your liking and then set the PivotLineValue to whatever threshold suits your tastes.
It's pretty interesting....just a graphical representation of what you'd expect....less slippage during high trading volumes and at certain times of the day (right before electronic trading break and right before midnight when the VWAP resets) the slippage is more likely for orders placed.
Just bear in mind that if you overlay this on a chart that goes back too far (or has any bar with zero volume) it will give you a div0 error. Maybe someone can help with a more elegant way to prevent that from happening.
If you can figure it out, I'd also like to somehow compare the actual up movements to up ticks and down movement to down ticks....(i.e. for a down bar, Absvalue(open-close)+Absvalue(Close-low) and opposite for an up bar. How do you get it to reference values in a bar that haven't been established yet? (i.e. how do I get it to determine whether it's an up or down bar?)
|