plugins/r-econ-data/skills/calculate-methods/SKILL.md
Methods for calculating statistics and estimates using economic data. Use when user asks to calculate or estimate quantities like percentiles, means, medians, shares, counts, or regression coefficients or regression-adjusted statistics.
npx skillsauth add Economic/epi-skills calculate-methodsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Often data over time is very noisy and moving averages can better extract signals. Use the R package slider for calculations over sliding windows like moving averages.
Use weighted.mean(vector, w = weight) for weighted means.
Use the MetricsWeighted package for weighted medians and percentiles: weighted_median(vector, w = weight) and weighted_quantile(vector, w = weight, probs = c(0.25, 0.50, 0.75)).
When using data that is assumed to be continuous but in practice is "bunched" at discrete points -- like reported hourly wages -- it can be helpful to smooth the estimated percentiles. One technique is to take a weighted average of nearby percentiles. For example, consider using the epidatatools package averaged_median(vector, w = weight) and averaged_quantile(vector, w = weight, probs = c(0.25, 0.50, 0.75)).
tools
--- name: research-remote-code description: Techniques for retrieving and investigating remote codebases and their documentation. Use when user provides a GitHub/GitLab URL to look at, asks to follow conventions from a remote repo, asks "how does package/library X implement/handle Y", or references any external repository's code, structure, or patterns. Examples: "follow the conventions in https://github.com/...", "look at how repo X does Y", "check this GitHub link". --- ## Accessing code from
testing
Common ways to validate or benchmark data analysis estimates using external sources. Use to confirm or test the plausibility of results from an economic analysis.
development
Provides useful economic data sources and ways to retrieve the data. Use when user asks for "prices", "inflation", "employment", "unemployment", "inequality", "productivity", "poverty", "CPS", "Census", "BLS", "BEA", "FRED", "IPUMS", "SWADL", "State of Working America Data Library".
testing
Create, edit, improve, or audit AgentSkills. Use when creating a new skill from scratch or when asked to improve, review, audit, tidy up, or clean up an existing skill or SKILL.md file. Also use when editing or restructuring a skill directory (moving files to references/ or scripts/, removing stale content, validating against the AgentSkills spec). Triggers on phrases like "create a skill", "author a skill", "tidy up a skill", "improve this skill", "review the skill", "clean up the skill", "audit the skill".