2
$\begingroup$

I'm doing intraday analysis on low volume stocks. There are just a few trades every day, but a whole host of bids and offers. In order to reduce the sparsity of the time series data I'd like to incorporate the trade, bid and offer price into a single price which I will apply standard time series analysis on. What are some good ways of doing this?

I've time segmented the measures into the standard open, high, low, close price measures. As a first approach I'm going to do analysis only on closing values from each time segment, meaning the last measured value for each measure. Thus I have close_bid, close_offer and close_trade. I'm going to omit the close_ part from now on.

Due to the sparsity any of the prices can be missing (or None is python speak).

The following (in Python code) is kind of what I'm thinking of doing:

def segment_and_merge_price_tics(price_tics, granularity)
    previous_price = None
    for t, bid, offer, trade in segment_price_tics(price_tics, granularity):
        if trade is not None:
            yield t, trade
        elif (trade is not None) and (bid is not None):
            yield t, (bid + offer)/2
        else:
            yield t, previous_price
        previous_price = price

def segment_price_tics(price_tics, granularity):
    # yields t, bid, offer and trade segmented based on granularity

In words: I am suggesting to simply use the average of the closing bid and offer price at time t when there were no trades. I also give preference to actual trades versus bids and offers.

What other strategies are there? I also have access to the depth of the bids and offers. Meaning I know how many give the lowest offer and highest bid for each tic.

Another thing that just occurred to me is that I might want to give preference to latest close price, not categorically the trade price. What if a trade comes in early in the time segment, is it really right to give it preference if there came bid and ask prices in just at the end of the time segment?

Any thoughts are welcomed.

$\endgroup$

1 Answer 1

2
$\begingroup$

The average would be called the mid-price, not the best in my opinion, but that depends on your modeling.

Another strategy is to weight the bid and offer prices according to size, also called the micro-price or bid-offer weighted price. This has the advantage of moving your calculated price closer to where it is traded as volume is depleted from whatever side is more traded if the book is not replenished.

p_{micro} = p_{offer}*v_{bid} + p_{bid}*v_{offer} / (v_{bid}+v_{offer})

$\endgroup$
4
  • $\begingroup$ Any source that shows that this price measure might be more appropriate than simple mid-price? $\endgroup$
    – Phun
    Feb 24, 2016 at 21:33
  • $\begingroup$ Like I mentioned, it depends on what you are trying to achieve. If you are trying to fit microstructure models that use the mid-price, of course you should go with the mid price. $\endgroup$ Feb 27, 2016 at 14:41
  • $\begingroup$ Otherwise, the explanation I have is rather indirect. Limit order book imbalance has some predictive value (risk.net/risk-magazine/technical-paper/2335976/…). Plus I believe it makes your series closer to thetypical Brownian Motion Hypothesis than using simple mid-price which might not move a lot at some time-frames. $\endgroup$ Feb 27, 2016 at 14:47
  • $\begingroup$ Interesting answer. $\endgroup$
    – Quantuple
    Mar 25, 2016 at 22:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.