wrds-data-access

Retrieve Compustat, CRSP, and TAQ datasets from WRDS via the Python API.

33|6|Updated Mar 17, 2026
One-click install
npx skills add https://github.com/xjtulyc/awesome-rosetta-skills --skill wrds-data-access
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: wrds-data-access
Source: https://github.com/xjtulyc/awesome-rosetta-skills/tree/main/skills/08-finance-academic/wrds-data-access
Command: npx skills add https://github.com/xjtulyc/awesome-rosetta-skills --skill wrds-data-access

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires wrds, pandas, numpy, sqlalchemy, matplotlib.

What problem does it solve?

It solves the problem of obtaining high-quality academic finance datasets from WRDS so you can build reproducible research inputs for accounting and returns analysis.

Core Features & Use Cases

  • WRDS API access to core databases: Pull Compustat fundamentals (e.g., comp.funda), CRSP stock returns (e.g., crsp.msf), and TAQ intraday trades/quotes (e.g., taq.ct_YYYYMMDD) using the Python wrds package.
  • Research-ready identifiers and merges: Support CRSP–Compustat linking via the CCM table (e.g., crsp.ccmxpf_lnkhist) to map gvkey to permno with date-valid constraints.
  • Dataset construction for empirical finance: Enable downstream computation of accounting ratios, market equity, portfolio returns, and microstructure metrics using retrieved fields.

Use case: You need a research-grade panel dataset combining annual fundamentals with CRSP returns and (optionally) intraday TAQ data, including correct gvkey→permno matching for your sample period.

Quick Start

Use the wrds-data-access skill to download Compustat fundamentals, CRSP returns, and the CRSP-Compustat link table from WRDS via the Python API, then compute key ratios and prepare merged datasets for your study.

Frequently Asked Questions about wrds-data-access

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I query Compustat and CRSP data from WRDS using Python?

Query Compustat and CRSP data from WRDS using the Python `wrds` package to execute SQL statements across WRDS schemas. This retrieves research-grade fundamentals and stock return panels for empirical finance workflows.

What is the best way to merge Compustat gvkey with CRSP permno identifiers?

Merge Compustat gvkey with CRSP permno identifiers using the CCM link table `crsp.ccmxpf_lnkhist`. This applies date-valid constraints to ensure accurate matching between fundamentals and returns data for your sample period.

Can I retrieve TAQ intraday trades and quotes data via the WRDS Python API?

Yes, you can retrieve TAQ intraday trades and quotes data via the WRDS Python API. Query tables like `taq.ct_YYYYMMDD` to support microstructure analysis alongside your daily returns and fundamentals datasets.

Do I need authenticated WRDS access to build empirical finance datasets?

Yes, authenticated WRDS access is required to build empirical finance datasets. You must establish Python WRDS connectivity with valid credentials to execute SQL queries and extract Compustat, CRSP, and TAQ data.

How do I compute market equity and accounting ratios after downloading CRSP and Compustat data?

Compute market equity and accounting ratios after downloading CRSP and Compustat data by preparing pandas and numpy dataframes. This downstream preparation enables portfolio return calculation and empirical finance analysis.