Develop high-performance C/C++ plugins for Stata using the stplugin.h SDK. Use when the user asks to create a Stata plugin, write C/C++ code for Stata, accelerate a Stata command with C, build cross-platform Stata plugins, or translate/port a Python or R package into Stata. Covers the full lifecycle: SDK setup, data flow, memory safety, .ado wrappers with preserve/merge, cross-platform compilation, performance optimization (pthreads, pre-sorted indices, XorShift RNG), debugging, and distribution via net install. Also includes a translation workflow for porting Python/R packages to Stata — wrapping existing C++ backends when available, or writing C from scratch when not.
Stata C/C++ Plugin Development Build high performance C/C++ plugins for Stata. This skill covers the full lifecycle from SDK setup through cross platform distribution, based on real experience building production Stata plugins for statistical imputation, random forests, string matching, and causal inference. This skill assumes macOS (Apple Silicon or Intel) as the development platform. Build commands, cross compilation workflows, and Docker instructions are all Mac oriented. The plugins…
Full body not shown for this license – view the source on GitHub →Copy a source-pinned command for your client. You run it yourself.
Destination: .claude/skills/stata-c-plugins · pinned to the source commit
# Run from your project root
git clone https://github.com/brycewang-stanford/Auto-Empirical-Research-Skills.git .skillboard-tmp
git -C .skillboard-tmp checkout 692e9fa3fea40bbdf614584d461851f8fb968ac2
mkdir -p ".claude/skills"
cp -r ".skillboard-tmp/skills/32-dylantmoore-stata-skill/plugins/stata-c-plugins/skills/stata-c-plugins" ".claude/skills/"
rm -rf .skillboard-tmpReview the source before running. This copies files into your project; it is not a one-click install and does not verify runtime safety.
sudo apt update && sudo apt install -y gitnpm install -g @anthropic-ai/claude-code# Run from your project root
git clone https://github.com/brycewang-stanford/Auto-Empirical-Research-Skills.git .skillboard-tmp
git -C .skillboard-tmp checkout 692e9fa3fea40bbdf614584d461851f8fb968ac2
mkdir -p ".claude/skills"
cp -r ".skillboard-tmp/skills/32-dylantmoore-stata-skill/plugins/stata-c-plugins/skills/stata-c-plugins" ".claude/skills/"
rm -rf .skillboard-tmpDestination: .claude/skills/stata-c-plugins
Scanner static-checks@0.1.0 · commit 692e9fa3fea4. Static checks cannot prove runtime safety – review the source and the exact diff before installing. How checks work.
Instructs shell/process/package operations that run commands on the host.
Evidence: brew install· fingerprint 1317bb7493250e7f