Complete working scripts demonstrating common workflows. Each script can be run directly with python examples/<filename>.py.
The canonical workflow for comparing a baseline and reform simulation, using both economic_impact_analysis() and ChangeAggregate.
Applying parametric reforms, comparing baseline and reform with ChangeAggregate, analysing winners and losers by income decile, and visualising results with Plotly.
Calculating net income and tax by income decile using representative microdata and Aggregate with quantile filters.
Loading enhanced CPS microdata, running a full microsimulation, and calculating statistics within income deciles.
Creating a custom dataset with varied employment income, running a single simulation, and visualising benefit phase-outs.
Same approach as the UK version, varying employment income from $0 to $200k and plotting household net income.
Using pe.uk.calculate_household() and pe.us.calculate_household() to compute taxes and benefits for individual custom households with flat keyword arguments and dot-access result objects.
Benchmarking how simulation.run() scales with dataset size.