Skip to content

Volume Clock, Gaps, and GOOG

October 23, 2012

GOOG unexpectedly disclosed their Q3 earnings early last week, on October 18th. While earnings were marginally interesting, much more amusing was the corresponding hiccup in intraday trading. This event provides an opportunity to dig into TAQ data, view through a HFT lens, and build intuition from some elegant ideas due to Mendelbrot, Clark, and Ané.

Begin by taking a look at the time-series plot of intraday trade prices for GOOG from the 18th (from one exchange):

The tape clearly illustrates some unhappy traders, with what appears to be a gap down in the noon hour (followed by trading halt until 3pm). Intraday dynamics can be better understood with a time-series summary of the corresponding trades and quotes:

Although the price appears to gap when viewed on a low-frequency daily chart, drilling into the noon hour illustrates the contrary:

Rather than a single print gap, the price action evolved more slowly over 12:30 to 12:40. The spread quickly expanded after 12:30, presumably driven by the jump in volume subsequent to disclosure. A 5,000 share trade printed shortly after 12:32, as spreads were beginning to stabilize. This precipitated some fear and greed, as market makers blew the spreads out to $4. Spread dynamics after noon appear to be fairly typical response to uncertainty and toxicity, as the summary is qualitatively similar to other similar events such as the morning after Bear in 2008.

By way of comparison, below is plot for TAQ summary on 3:25 – 4pm:

Now that we are familiar with the TAQ action as measured in human chronology, let’s view it through a different lens—following the intuition from Mandelbrot (1963), Clark (1971), and most recently Easley et al. (2012).

To do so, begin by considering trades for GOOG from another day which is more normal, say the following day Oct 19. Start with human chronology, and calculate the time series of first differences for 1 and 5 minute bars. Next estimate the Epanechnikov kernel density from first differences. Finally, fit the corresponding Gaussian for the same first differences. Or, in R:

# first differences
min1Diff <- diff(to.minutes(trades$price)[,4], na.pad=F)
min10Diff <- diff(to.minutes5(trades$price)[,4], na.pad=F)

# kernel densities
min1Density <- density(min1Diff, kernel="epanechnikov")
min10Density <- density(min10Diff, kernel="epanechnikov")

# corresponding normals
min1Normal <- fitdistr(coredata(min1Diff), "normal")$estimate
min10Normal <- fitdistr(coredata(min10Diff), "normal")$estimate

Which are plotted below for Oct 19, with solid red being 1-minute difference density and solid blue being 5-minute difference bars (ignore black for now); Gaussian fits for the same differences of each are dashed:

This reproduces the familiar stylized distribution of high-frequency returns, consistent with Figure 1 from Clark (1971) and Exhibit 2 from Easley et al. (2012). Although certainly leptokurtic, the distributions are not too dissimilar from normal.

Now, ignore chronological time and instead consider the trades from the perspective of a clock based on volume of shares traded over the day. In other words, generate a new process defined as the sequence of prices coinciding with shares traded on equal-sized partitions of total volume over the day. This process generates a “volume clock” for the trades, in doing so exemplifying a beautiful time-series transformation.

A similar kernel density can be estimated from this trade volume clock, which is plotted above in black (with dashed corresponding normal fit), assuming partition size of 50. This exhibits distribution characteristics consistent with Exhibit 2 from Easley et al. (2012).

With intuition on volume clock densities, we can finally take a look at Oct 18 through the lens of a computer via the following plot:

Needless to say, this plot for Oct 18 looks nothing like the previous plot for Oct 19. The normal fits for both 5-min bars (blue) and volume clock (black) are especially interesting, as they have little resemblance to their corresponding kernel estimates. Care is required for trading on days that look like this.

For those interested to learn more, see Clark (1971) for theory, including subordinated stochastic processes (originally due to Bochner (1960)). Ané and Geman (2000) apply a bit more sophistication, including arguing in favor of cumulative transaction count rather than cumulative traded volume. Perhaps worth a follow-up post to see if this still makes sense, given current era of predominantly algorithmic program trading.

The R code to generate the above plots is:

plot(trades20121018$price, main="GOOG Trades (2012-10-18)")
plotTAQSummary("GOOG", "2012-10-18", as.POSIXct("2012-10-18 09:30:00"), as.POSIXct("2012-10-18 16:05:00"))
plotTAQSummary("GOOG", "2012-10-18 | 12:00 - 13:00", as.POSIXct("2012-10-18 12:00:00"), as.POSIXct("2012-10-18 13:00:00"))
plotTAQSummary("GOOG", "2012-10-18 | 15:00 - 16:00", as.POSIXct("2012-10-18 15:25:00"), as.POSIXct("2012-10-18 16:05:00"))
plotTimeChangeDensity("GOOG", as.Date("2012-10-19"), trades20121019)
plotTimeChangeDensity("GOOG", as.Date("2012-10-18"), trades20121018)

And, a bit of literature on subordinated processes, volume clocks, and price processes:

  • Bochner, Harmonic Analysis and the Theory of Probability, University of California Press, Berkeley, 1960.
  • Mandelbrot, “The Variation of Certain Speculative Prices”, Journal of Business, Vol. 36 (1963), p. 394-419.
  • Clark, “A Subordinated Stochastic Process Model with Finite Variance for Speculative Prices”. Center for Economic Research. University of Minnesota, 1971.
  • Ané and Geman, “Order Flow, Transaction Clock, and Normality of Asset Returns”, Journal of Finance, Vol. 55, No. 5 (2000), pp. 2259-2284.
  • Murphy and Izzeldin, “Order Flow, Transaction Clock, and Normality of Asset Returns: Ané and Geman (2000) Revisited”, 2006.
  • Easley, de Prado, and O’Hara, “The Volume Clock: Insights into the High Frequency Paradigm”. Journal of Portfolio Management, May 2012.
11 Comments leave one →
  1. Eduardo permalink
    October 26, 2012 3:18 pm

    Nice. Thank you. Which R packages are you using? I was looking at RTAQ and highfrequency but do not see those functions implemented there.

    Eduardo

    • October 26, 2012 10:14 pm

      @Eduardo: Above functions are from private packages, though built on the usual rfinance packages (e.g. xts). I can post code for the plotting functions, if desired.

      • Eduardo permalink
        October 27, 2012 4:22 am

        If possible and not to much hasle for you to share, please. Would like to see how transformation to trade volume clock is done in R.

  2. October 31, 2012 5:07 pm

    Reblogged this on Convoluted Volatility – StatArb,VolArb; Macro..

  3. November 26, 2012 11:39 pm

    Hi Quantivity,

    What exactly is Volume Price? Can you elaborate?
    Thanks
    Shoonya

    • quantivity permalink*
      November 27, 2012 11:23 pm

      @Shoonya: please clarify in what context are you referring, as I did not reference that term in this post?

      • Mayank permalink
        December 27, 2012 3:12 am

        Shoonya is refering to first plot under TAQ graphs (Voluem Price, Price, Spread, Volume)

  4. July 17, 2018 10:26 pm

    Здравствуйте уважаемее будующие или состоявшиеся родители,спешу поделиться с Вами очень полезной информацией котороя будет полезна при выборе товаров для ваших малышей: интернет магазин помощь маме ребенку не должно быть тесно лежать и, в то же время, слишком большая люлька не создаст нужного комфорта.но в продаже встречаются и модели весом более десяти кг.для холодных регионов такая коляска не подойдет.

  5. February 1, 2020 5:41 pm

    способы заработка – безопасность в сети, продвижение вконтакте

  6. March 11, 2020 3:56 pm

    hidra – хидра, худра

  7. March 13, 2020 6:31 pm

    her explanation https://superslots-casino.site

Leave a comment