Skip to content
Agentmart
Submit a tool

economics-analysis

Economic analysis including econometrics, causal inference, time series economics, game theory, welfare analysis, and economic modeling.

Skill by beita6969

IndexedMIT★ 1,019
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/beita6969-economics-analysis

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Economic analysis including econometrics, causal inference, time series economics, game theory, welfare analysis, and economic modeling. Use when user works with economic data, regression analysis, instrumental variables, difference-in-differences, RDD, panel data, or economic theory. Triggers on "econometrics", "regression", "causal inference", "instrumental variable", "difference-in-differences", "panel data", "game theory", "supply demand", "GDP", "inflation", "economic model".

Use cases: data, ml

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/economics-analysis

What's inside

Skill name
economics-analysis
Description
Economic analysis including econometrics, causal inference, time series economics, game theory, welfare analysis, and economic modeling. Use when user works with economic data, regression analysis, instrumental variables, difference-in-differences, RDD, panel data, or economic theory. Triggers on "econometrics", "regression", "causal inference", "instrumental variable", "difference-in-differences", "panel data", "game theory", "supply demand", "GDP", "inflation", "economic model".
License
MIT
Instructions
130 lines in SKILL.md · view on GitHub

Before installing

  • Instructions call the network

Agent Skills spec issues

  • body: contains an absolute path from the author's machine

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Economics Analysis

Econometrics and economic modeling. Venv: `source /Users/zhangmingda/clawd/.venv/bin/activate`

## Causal Inference Methods

### Selection Guide
| Method | When to Use | Key Assumption |
|--------|------------|----------------|
| RCT | Can randomize treatment | Random assignment |
| IV (2SLS) | Endogeneity, have instrument | Exclusion restriction |
| DiD | Policy change, panel data | Parallel trends |
| RDD | Treatment at threshold | Continuity at cutoff |
| Matching/PSM | Observational, rich covariates | Selection on observables |
| Synthetic Control | Aggregate intervention, few treated | Parallel trends (weighted) |

### Difference-in-Differences
```python
import statsmodels.formula.api as smf

# Basic DiD
model = smf.ols('outcome ~ treated * post + C(unit) + C(time)', data=df).fit(cov_type='cluster', cov_kwds={'groups': df['unit']})
print(model.summary())
# DiD estimate = coefficient on treated:post interaction
```

### Instrumental Variables (2SLS)
```python
from linearmodels.iv import IV2SLS

# Y = β₀ + β₁X + ε, where X is endogenous
# Z is the instrument
model = IV2SLS.from_formula('outcome ~ 1 + controls + [endogenous ~ instrument]', data=df)
result = model.fit(cov_type='robust')
print(result.summary)
```

### Regression Discontinuity
```python
# Local linear regression around cutoff
from sklearn.linear_model import LinearRegression

bandwidth = 5  # choose appropriately
cutoff = 0
left = df[(df['running'] >= cutoff - bandwidth) & (df['running'] < cutoff)]
right = df[(df['running'] >= cutoff) & (df['running'] <= cutoff + bandwidth)]

# Fit separate regressions
model_left = LinearRegression().fit(left[['running']], left['outcome'])
model_right = LinearRegression().fit(right[['running']], right['outcome'])

# RDD estimate
rdd_effect = model_right.predict([[cutoff]])[0] - model_left.predict([[cutoff]])[0]
```

## Panel Data

```python
from linearmodels.panel import PanelOLS, RandomEffects, BetweenOLS

df = df.set_index(['entity', 'time'])

# Fixed effects
fe = PanelOLS.from_formula('y ~ x1 + x2 + EntityEffects + TimeEffects', data=df)
fe_result = fe.fit(cov_type='clustered', cluster_entity=True)

# Random effects
re = RandomEffects.from_formula('y ~ x1 + x2', data=df)
re_result = re.fit()

# Hausman test: FE vs RE
# If significant → use FE
```

## Game Theory

```python
import numpy as np
from scipy.optimize import linprog

# Nash equilibrium (2-player, finite)
def find_nash_pure(payoff_A, payoff_B):
    """Find pure strategy Nash equilibria"""
    nash = []
    rows, cols = payoff_A.shape
    for i in range(rows):
        for j in range(cols):
            # Check if i is best response to j, and j is best response to i
            if payoff_A[i,j] == max(payoff_A[:,j]) and payoff_B[i,j] == max(payoff_B[i,:]):
                nash.append((i, j))
    return nash

# Example: Prisoner's Dilemma
A = np.array([[-1, -3], [0, -2]])  # Row player payoffs
B = np.array([[-1, 0], [-3, -2]])  # Column player payoffs
print(f"Nash equilibria: {find_nash_pure(A, B)}")
```

## Economic Data Sources

| Source | Data | Access |
|--------|------|--------|
| FRED (St. Louis Fed) | US macro data | `https://api.stlouisfed.org/fred/` |
| World Bank | Global development | `https://api.worldbank.org/v2/` |
| IMF | International finance | REST API |
| BLS | US labor statistics | REST API |
| OECD | OECD country data | REST API |
| Penn World Table | Cross-country GDP | Download |
| CNKI/CSMAR | Chinese economic data | Institutional access |

### FRED API
```bash
# Get GDP data (need API key)
curl -s "https://api.stlouisfed.org/fred/series/observations?series_id=GDP&api_key=YOUR_KEY&file_type=json"
```

### World Bank API
```bash
curl -s "https://api.worldbank.org/v2/country/CHN/indicator/NY.GDP.MKTP.CD?format=json&per_page=20"

From beita6969/ScienceClaw, MIT.

More from beita6969/ScienceClaw

Signals

Stars
1,019
Forks
109
Open issues
1
Last commit (this folder)
Mar 12, 2026 (7 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from beita6969

Cite this page

economics-analysis skill. Agent Mart. https://agentmart.dev/skills/beita6969-economics-analysis (last updated 2026-10-24)