The TAQ data query scripts are located in subdirectories of the $RAP30/Scripts directory on the server. See the table below for a description of each script file.
Script name |
Description |
---|---|
tick_qry1.sql |
Get all ticks for a specified set of 100 securities for a specified three-hour time period on a specified trade date. |
tick_qry2.sql |
Determine the volume-weighted price of a security considering only the ticks in a specified three-hour interval. |
tick_qry3.sql |
Determine the top 10 percentage losers for the specified date on the specified exchanges, sorted by percentage loss. The loss is calculated as a percentage of the last trade price of the previous day. |
tick_qry4.sql |
Determine the top 10 most active stocks for a specified date, sorted by cumulative trade volume, by considering all trades. |
tick_qry5.sql |
Find the most active stocks in the COMPUTER industry (use SIC code). |
tick_qry6.sql |
Find the 10 stocks with the highest percentage spreads. Spread is the difference between the last ask-price and the last bid-price. Percentage spread is calculated as a percentage of the bid-point price (average of ask and bid price). |
An additional
SQL script setup_tick_qry3_last_price.sql
should be run on the RAPCache database at the end of each trading
day to capture the last price of that day. This data is referenced
by tick_qry3.sql. For more information, see “setup_tick_qry3_last_price.sql”.