Learn with runnable examples
Start with a task, inspect the complete command sequence, and open the matching do-file in stats.camp.
Independent software. Not affiliated with, sponsored by, or endorsed by StataCorp LLC.
Open and import data
- Open a .dta file onlineLoad a bundled Stata-format dataset and inspect its variables.
- Import a CSV with import delimitedLoad a delimited file and verify its rows, types, and missing values.
- Run a do-file in the browserKeep commands in a reusable script and run them without a desktop installation.
- Run a browser workflow on a ChromebookPrepare a zero-install classroom workflow on a managed device.
Create and clean variables
- Calculate row means and totals with egenUse rowmean(), rowtotal(), mean(), count(), and group() in one runnable example.
- Report, tag, and drop duplicate recordsChoose a key, inspect repeated rows, and verify duplicate removal.
- Generate variables and cumulative sumsCreate calculated variables, indicators, and ordered running totals.
- Replace selected and missing valuesChange a checked subset while preserving the rest of a variable.
- Recode values and rangesMap numeric ranges into labeled categories without changing the source.
- Reshape data from wide to longConvert repeated measurements between column and row layouts.
- Merge datasets by an identifierJoin files and diagnose matched and unmatched observations.
Summarize and compare groups
- Summarize variables by groupCalculate counts, means, standard deviations, ranges, and grouped summaries.
- Select statistics with tabstatBuild compact summary tables for several variables and groups.
- Create a frequency table with tabulateBuild one-way and two-way tables of categorical variables.
- Collapse data by groupReplace observation-level rows with grouped means and counts.
- Run a two-sample t-testCompare two group means with a confidence interval and p-value.
- Run a Wilcoxon rank-sum testCompare two independent groups with ranks, exact inference, and porder.
Correlation and regression
- Calculate a correlation with correlate or corrBuild a Pearson correlation matrix and inspect its analysis sample.
- Calculate pairwise correlations with pwcorrUse the observations available for each pair of variables.
- Run an OLS regressionFit a model with categorical predictors and robust standard errors.
- Run a logit regressionFit a binary-response model with robust standard errors.
Predictions and diagnostics
Replicate published research
Check compatibility before adapting an example
Each example documents the stats.camp behavior it actually uses. An existing do-file can still depend on other options, stored results, user-written packages, or exact formatting that is not implemented.
Review the maintained command and limitation table before moving a consequential workflow.
Try the workflow
Open the live project, inspect the existing do-file, and adapt the workflow. No stats.camp account is required for the demo.
Try the live demo