Back to Blog

automation

Event Study CARs: A Rigorous Skill for Financial Agents

A scenario-driven guide to using the event-study-cars skill for publication-quality cumulative abnormal return computations in AI agents.

OpenAgentSkillPublished:

Where this fits

A quant researcher asks their AI agent to compute cumulative abnormal returns (CARs) around a recent earnings surprise. The agent runs a quick market-model regression, sums residuals, and reports a number — but without proper test statistics, thin-trading adjustments, or event-window guards. The result is statistically fragile and unusable for a paper or trading decision. This skill fills that gap by giving agents a complete, publication-ready event-study methodology that matches Stata's eventstudy2 package.

Why agents benefit

  • Stata-level rigor in Python: Implements the full Kaspereit eventstudy2 methodology, so agents produce CARs with the same robustness as academic finance software.
  • Thin-trading handling: Automatically applies trade-to-trade return adjustments when stocks don't trade daily, avoiding biased estimates.
  • Multiple test statistics: Includes Patell, BMP, Kolari-Pynnonen, generalized sign, Wilcoxon, and GRANK-T tests, giving agents the right tool for different data distributions and hypotheses.
  • Boundary contamination guards: Checks event windows against overlapping estimation periods and other events, preventing silent errors.
  • Dateline construction and mapping: Handles the messy work of converting calendar dates to event time and aligning with market data, a common source of agent mistakes.

Practical scenarios

Earnings Announcement CARs

An agent needs to measure the market reaction to quarterly earnings surprises for a portfolio of 500 stocks. The skill correctly constructs estimation windows (e.g., 120 days before the event) and event windows (e.g., [-1, +1]), applies the market model, and outputs CAARs with cross-sectional test statistics — ready for a research note.

Merger and Acquisition Event Studies

When evaluating the value creation of a proposed merger, an agent can compute CARs for target and acquirer firms around the announcement date. The skill's ability to handle varying event windows and thin trading is critical for smaller targets that may not trade daily.

Regulatory Policy Impact Analysis

A policy analyst wants to quantify the effect of a new regulation on a sector. The agent uses the skill to compute AARs and CAARs over a longer event window (e.g., [-5, +10]) and applies the generalized sign test to check whether the observed abnormal returns are systematic or noise.

Add it to your agent workflow

Install the skill directly from the command line:

npx skills add kennethkhoocy/applied-micro-skills --skill event-study-cars

Once installed, your agent can invoke the skill with parameters like ticker, event_date, estimation_window, and event_window. For example:

# Agent pseudo-code
from event_study_cars import run_event_study

results = run_event_study(
    ticker="AAPL",
    event_date="2025-02-01",
    estimation_window=(-120, -11),
    event_window=(-1, 1),
    market_index="SPY"
)

The skill returns a structured output with CARs, test statistics, and diagnostic warnings.

Compare before adopting

Before committing, compare this skill against other event-study implementations (e.g., eventstudy in R, or custom code). Assess: the quality of the test statistics (does it include Kolari-Pynnonen? that's a differentiator), the freshness of maintenance (check the GitHub repo's last commit), and whether the skill's output format aligns with your downstream analysis pipeline. Also consider alternatives like empyrical or statsmodels if you only need basic CARs without robust tests.

Why it is worth tracking

With 47 stars and an active author (kennethkhoocy), this skill is part of a broader applied-micro-skills collection that signals community interest in finance-specific agent capabilities. The fact that it replicates a well-known Stata package suggests the methodology is battle-tested. It's worth evaluating now if your agents handle any event-study or abnormal-return tasks — especially if you need publication-quality output. For a full comparison of similar skills, see OpenAgentSkill's listing. Track it to stay ahead of the growing trend of specialized, rigorous financial analysis skills for agents.

Featured Skill

event-study-cars

Skill by kennethkhoocy