Koren.dev
← Back to home

Software

-- Load the extension
LOAD stata_dta;

-- Read Stata file directly into DuckDB
SELECT * FROM read_stata_dta('data/survey.dta');

-- Query with SQL operations
SELECT region, AVG(income) 
FROM read_stata_dta('data/survey.dta') 
GROUP BY region;
  • duckdb
  • cpp

stata-dta

High-performance DuckDB extension for reading Stata .dta files

Download
using Targets

add(x, y) = x + y

@target a = 1
@target b = 2
@target c = add(a, b)

@get c
  • julia

Targets.jl

Computational pipeline management for Julia

Download
using Kezdi
@use "distances.dta"
@replace distance = 5 @if distance < 5
  • julia

Kezdi.jl

A data analysis package for economists

Download
xt2treatments y, treatment(treatmentB) control(treatmentA) pre(1) post(3) weighting(equal)
  • stata

xt2treatments

event studies with two treatments

Download
xthdidregress ra (y) (d), group(i)
eventbaseline, pre(5) post(5) baseline(-1) graph
  • stata

eventbaseline

Correct Event Study After `xthdidregress`

Download
here
import delimited "${here}/data/raw/bls/employment.csv"
  • stata

here

A simpler way to find your files.

Download