Learn R Programming

highfrequency (version 1.0.1)

autoSelectExchangeQuotes: Retain only data from the stock exchange with the highest volume

Description

Filters raw quote data and return only data that stems from the exchange with the highest value for the sum of "BIDSIZ" and "OFRSIZ", i.e. the highest quote volume.

Usage

autoSelectExchangeQuotes(qData, printExchange = TRUE)

Value

data.table or xts object depending on input.

Arguments

qData

a data.table or xts object with at least a column "EX", indicating the exchange symbol and columns "BIDSIZ" and "OFRSIZ", indicating the volume available at the bid and ask respectively.

printExchange

indicates whether the chosen exchange is printed on the console, default is TRUE. The possible exchanges are:

  • A: AMEX

  • N: NYSE

  • B: Boston

  • P: Arca

  • C: NSX

  • T/Q: NASDAQ

  • D: NASD ADF and TRF

  • X: Philadelphia

  • I: ISE

  • M: Chicago

  • W: CBOE

  • Z: BATS

Author

Jonathan Cornelissen, Kris Boudt, Onno Kleen, and Emil Sjoerup.

Examples

Run this code
autoSelectExchangeQuotes(sampleQDataRaw)

Run the code above in your browser using DataLab