[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6XFR8Y27DT83XR92FSRXSD0":3,"skill-same:01M6XFR8Y27DT83XR92FSRXSD0":100},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":23,"publishedAt":44,"linkOnly":45,"markdownContent":46,"markdownBody":47,"frontMatter":48,"refName":52,"commitSha":53,"skillDirectory":54,"forksCount":14,"repositoryHtmlUrl":55,"repositoryHomepageUrl":6,"ownerHtmlUrl":56,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":57,"install":58,"resources":71},"01M6XFR8Y27DT83XR92FSRXSD0","statistical-analysis",null,"Guided statistical analysis with test selection and reporting. Use when you need help choosing appropriate tests for your data, assumption checking, power analysis, and APA-formatted results. Best for academic research reporting, test selection guidance. For implementing specific models programmatically use statsmodels.","fadrienne\u002FMyGitHub","fadrienne","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F197874571?v=4","01M6X64V8VWCRSMFZ4EPS2BWXG","Francesca Adrienne","01M6X64VD5MW4F9PHDWQKS7ZAF",0,"MIT","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000008","测试与质量","SCENARIO","使用场景",[24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43],"analysis","statistical analysis","power","when","academic research","for","implementing","you","with","synthetic","tests","selection","research","use","results","coding","statsmodels","data","reporting","test","2026-11-10 10:12:30",false,"---\nname: statistical-analysis\ndescription: Guided statistical analysis with test selection and reporting. Use when you need help choosing appropriate tests for your data, assumption checking, power analysis, and APA-formatted results. Best for academic research reporting, test selection guidance. For implementing specific models programmatically use statsmodels.\ncategory: coding\nlicense: MIT license\nmetadata:\n    skill-author: Synthetic Sciences\n---\n\n# Statistical Analysis\n\n## Overview\n\nStatistical analysis is a systematic process for testing hypotheses and quantifying relationships. Conduct hypothesis tests (t-test, ANOVA, chi-square), regression, correlation, and Bayesian analyses with assumption checks and APA reporting. Apply this skill for academic research.\n\n## When to Use This Skill\n\nThis skill should be used when:\n- Conducting statistical hypothesis tests (t-tests, ANOVA, chi-square)\n- Performing regression or correlation analyses\n- Running Bayesian statistical analyses\n- Checking statistical assumptions and diagnostics\n- Calculating effect sizes and conducting power analyses\n- Reporting statistical results in APA format\n- Analyzing experimental or observational data for research\n\n---\n\n## Core Capabilities\n\n### 1. Test Selection and Planning\n- Choose appropriate statistical tests based on research questions and data characteristics\n- Conduct a priori power analyses to determine required sample sizes\n- Plan analysis strategies including multiple comparison corrections\n\n### 2. Assumption Checking\n- Automatically verify all relevant assumptions before running tests\n- Provide diagnostic visualizations (Q-Q plots, residual plots, box plots)\n- Recommend remedial actions when assumptions are violated\n\n### 3. Statistical Testing\n- Hypothesis testing: t-tests, ANOVA, chi-square, non-parametric alternatives\n- Regression: linear, multiple, logistic, with diagnostics\n- Correlations: Pearson, Spearman, with confidence intervals\n- Bayesian alternatives: Bayesian t-tests, ANOVA, regression with Bayes Factors\n\n### 4. Effect Sizes and Interpretation\n- Calculate and interpret appropriate effect sizes for all analyses\n- Provide confidence intervals for effect estimates\n- Distinguish statistical from practical significance\n\n### 5. Professional Reporting\n- Generate APA-style statistical reports\n- Create publication-ready figures and tables\n- Provide complete interpretation with all required statistics\n\n---\n\n## Workflow Decision Tree\n\nUse this decision tree to determine your analysis path:\n\n```\nSTART\n│\n├─ Need to SELECT a statistical test?\n│  └─ YES → See \"Test Selection Guide\"\n│  └─ NO → Continue\n│\n├─ Ready to check ASSUMPTIONS?\n│  └─ YES → See \"Assumption Checking\"\n│  └─ NO → Continue\n│\n├─ Ready to run ANALYSIS?\n│  └─ YES → See \"Running Statistical Tests\"\n│  └─ NO → Continue\n│\n└─ Need to REPORT results?\n   └─ YES → See \"Reporting Results\"\n```\n\n---\n\n## Test Selection Guide\n\n### Quick Reference: Choosing the Right Test\n\nUse `references\u002Ftest_selection_guide.md` for comprehensive guidance. Quick reference:\n\n**Comparing Two Groups:**\n- Independent, continuous, normal → Independent t-test\n- Independent, continuous, non-normal → Mann-Whitney U test\n- Paired, continuous, normal → Paired t-test\n- Paired, continuous, non-normal → Wilcoxon signed-rank test\n- Binary outcome → Chi-square or Fisher's exact test\n\n**Comparing 3+ Groups:**\n- Independent, continuous, normal → One-way ANOVA\n- Independent, continuous, non-normal → Kruskal-Wallis test\n- Paired, continuous, normal → Repeated measures ANOVA\n- Paired, continuous, non-normal → Friedman test\n\n**Relationships:**\n- Two continuous variables → Pearson (normal) or Spearman correlation (non-normal)\n- Continuous outcome with predictor(s) → Linear regression\n- Binary outcome with predictor(s) → Logistic regression\n\n**Bayesian Alternatives:**\nAll tests have Bayesian versions that provide:\n- Direct probability statements about hypotheses\n- Bayes Factors quantifying evidence\n- Ability to support null hypothesis\n- See `references\u002Fbayesian_statistics.md`\n\n---\n\n## Assumption Checking\n\n### Systematic Assumption Verification\n\n**ALWAYS check assumptions before interpreting test results.**\n\nUse the provided `scripts\u002Fassumption_checks.py` module for automated checking:\n\n```python\nfrom scripts.assumption_checks import comprehensive_assumption_check\n\n# Comprehensive check with visualizations\nresults = comprehensive_assumption_check(\n    data=df,\n    value_col='score',\n    group_col='group',  # Optional: for group comparisons\n    alpha=0.05\n)\n```\n\nThis performs:\n1. **Outlier detection** (IQR and z-score methods)\n2. **Normality testing** (Shapiro-Wilk test + Q-Q plots)\n3. **Homogeneity of variance** (Levene's test + box plots)\n4. **Interpretation and recommendations**\n\n### Individual Assumption Checks\n\nFor targeted checks, use individual functions:\n\n```python\nfrom scripts.assumption_checks import (\n    check_normality,\n    check_normality_per_group,\n    check_homogeneity_of_variance,\n    check_linearity,\n    detect_outliers\n)\n\n# Example: Check normality with visualization\nresult = check_normality(\n    data=df['score'],\n    name='Test Score',\n    alpha=0.05,\n    plot=True\n)\nprint(result['interpretation'])\nprint(result['recommendation'])\n```\n\n### What to Do When Assumptions Are Violated\n\n**Normality violated:**\n- Mild violation + n > 30 per group → Proceed with parametric test (robust)\n- Moderate violation → Use non-parametric alternative\n- Severe violation → Transform data or use non-parametric test\n\n**Homogeneity of variance violated:**\n- For t-test → Use Welch's t-test\n- For ANOVA → Use Welch's ANOVA or Brown-Forsythe ANOVA\n- For regression → Use robust standard errors or weighted least squares\n\n**Linearity violated (regression):**\n- Add polynomial terms\n- Transform variables\n- Use non-linear models or GAM\n\nSee `references\u002Fassumptions_and_diagnostics.md` for comprehensive guidance.\n\n---\n\n## Running Statistical Tests\n\n### Python Libraries\n\nPrimary libraries for statistical analysis:\n- **scipy.stats**: Core statistical tests\n- **statsmodels**: Advanced regression and diagnostics\n- **pingouin**: User-friendly statistical testing with effect sizes\n- **pymc**: Bayesian statistical modeling\n- **arviz**: Bayesian visualization and diagnostics\n\n### Example Analyses\n\n#### T-Test with Complete Reporting\n\n```python\nimport pingouin as pg\nimport numpy as np\n\n# Run independent t-test\nresult = pg.ttest(group_a, group_b, correction='auto')\n\n# Extract results\nt_stat = result['T'].values[0]\ndf = result['dof'].values[0]\np_value = result['p-val'].values[0]\ncohens_d = result['cohen-d'].values[0]\nci_lower = result['CI95%'].values[0][0]\nci_upper = result['CI95%'].values[0][1]\n\n# Report\nprint(f\"t({df:.0f}) = {t_stat:.2f}, p = {p_value:.3f}\")\nprint(f\"Cohen's d = {cohens_d:.2f}, 95% CI [{ci_lower:.2f}, {ci_upper:.2f}]\")\n```\n\n#### ANOVA with Post-Hoc Tests\n\n```python\nimport pingouin as pg\n\n# One-way ANOVA\naov = pg.anova(dv='score', between='group', data=df, detailed=True)\nprint(aov)\n\n# If significant, conduct post-hoc tests\nif aov['p-unc'].values[0] \u003C 0.05:\n    posthoc = pg.pairwise_tukey(dv='score', between='group', data=df)\n    print(posthoc)\n\n# Effect size\neta_squared = aov['np2'].values[0]  # Partial eta-squared\nprint(f\"Partial η² = {eta_squared:.3f}\")\n```\n\n#### Linear Regression with Diagnostics\n\n```python\nimport statsmodels.api as sm\nfrom statsmodels.stats.outliers_influence import variance_inflation_factor\n\n# Fit model\nX = sm.add_constant(X_predictors)  # Add intercept\nmodel = sm.OLS(y, X).fit()\n\n# Summary\nprint(model.summary())\n\n# Check multicollinearity (VIF)\nvif_data = pd.DataFrame()\nvif_data[\"Variable\"] = X.columns\nvif_data[\"VIF\"] = [variance_inflation_factor(X.values, i) for i in range(X.shape[1])]\nprint(vif_data)\n\n# Check assumptions\nresiduals = model.resid\nfitted = model.fittedvalues\n\n# Residual plots\nimport matplotlib.pyplot as plt\nfig, axes = plt.subplots(2, 2, figsize=(12, 10))\n\n# Residuals vs fitted\naxes[0, 0].scatter(fitted, residuals, alpha=0.6)\naxes[0, 0].axhline(y=0, color='r', linestyle='--')\naxes[0, 0].set_xlabel('Fitted values')\naxes[0, 0].set_ylabel('Residuals')\naxes[0, 0].set_title('Residuals vs Fitted')\n\n# Q-Q plot\nfrom scipy import stats\nstats.probplot(residuals, dist=\"norm\", plot=axes[0, 1])\naxes[0, 1].set_title('Normal Q-Q')\n\n# Scale-Location\naxes[1, 0].scatter(fitted, np.sqrt(np.abs(residuals \u002F residuals.std())), alpha=0.6)\naxes[1, 0].set_xlabel('Fitted values')\naxes[1, 0].set_ylabel('√|Standardized residuals|')\naxes[1, 0].set_title('Scale-Location')\n\n# Residuals histogram\naxes[1, 1].hist(residuals, bins=20, edgecolor='black', alpha=0.7)\naxes[1, 1].set_xlabel('Residuals')\naxes[1, 1].set_ylabel('Frequency')\naxes[1, 1].set_title('Histogram of Residuals')\n\nplt.tight_layout()\nplt.show()\n```\n\n#### Bayesian T-Test\n\n```python\nimport pymc as pm\nimport arviz as az\nimport numpy as np\n\nwith pm.Model() as model:\n    # Priors\n    mu1 = pm.Normal('mu_group1', mu=0, sigma=10)\n    mu2 = pm.Normal('mu_group2', mu=0, sigma=10)\n    sigma = pm.HalfNormal('sigma', sigma=10)\n\n    # Likelihood\n    y1 = pm.Normal('y1', mu=mu1, sigma=sigma, observed=group_a)\n    y2 = pm.Normal('y2', mu=mu2, sigma=sigma, observed=group_b)\n\n    # Derived quantity\n    diff = pm.Deterministic('difference', mu1 - mu2)\n\n    # Sample\n    trace = pm.sample(2000, tune=1000, return_inferencedata=True)\n\n# Summarize\nprint(az.summary(trace, var_names=['difference']))\n\n# Probability that group1 > group2\nprob_greater = np.mean(trace.posterior['difference'].values > 0)\nprint(f\"P(μ₁ > μ₂ | data) = {prob_greater:.3f}\")\n\n# Plot posterior\naz.plot_posterior(trace, var_names=['difference'], ref_val=0)\n```\n\n---\n\n## Effect Sizes\n\n### Always Calculate Effect Sizes\n\n**Effect sizes quantify magnitude, while p-values only indicate existence of an effect.**\n\nSee `references\u002Feffect_sizes_and_power.md` for comprehensive guidance.\n\n### Quick Reference: Common Effect Sizes\n\n| Test | Effect Size | Small | Medium | Large |\n|------|-------------|-------|--------|-------|\n| T-test | Cohen's d | 0.20 | 0.50 | 0.80 |\n| ANOVA | η²_p | 0.01 | 0.06 | 0.14 |\n| Correlation | r | 0.10 | 0.30 | 0.50 |\n| Regression | R² | 0.02 | 0.13 | 0.26 |\n| Chi-square | Cramér's V | 0.07 | 0.21 | 0.35 |\n\n**Important**: Benchmarks are guidelines. Context matters!\n\n### Calculating Effect Sizes\n\nMost effect sizes are automatically calculated by pingouin:\n\n```python\n# T-test returns Cohen's d\nresult = pg.ttest(x, y)\nd = result['cohen-d'].values[0]\n\n# ANOVA returns partial eta-squared\naov = pg.anova(dv='score', between='group', data=df)\neta_p2 = aov['np2'].values[0]\n\n# Correlation: r is already an effect size\ncorr = pg.corr(x, y)\nr = corr['r'].values[0]\n```\n\n### Confidence Intervals for Effect Sizes\n\nAlways report CIs to show precision:\n\n```python\nfrom pingouin import compute_effsize_from_t\n\n# For t-test\nd, ci = compute_effsize_from_t(\n    t_statistic,\n    nx=len(group1),\n    ny=len(group2),\n    eftype='cohen'\n)\nprint(f\"d = {d:.2f}, 95% CI [{ci[0]:.2f}, {ci[1]:.2f}]\")\n```\n\n---\n\n## Power Analysis\n\n### A Priori Power Analysis (Study Planning)\n\nDetermine required sample size before data collection:\n\n```python\nfrom statsmodels.stats.power import (\n    tt_ind_solve_power,\n    FTestAnovaPower\n)\n\n# T-test: What n is needed to detect d = 0.5?\nn_required = tt_ind_solve_power(\n    effect_size=0.5,\n    alpha=0.05,\n    power=0.80,\n    ratio=1.0,\n    alternative='two-sided'\n)\nprint(f\"Required n per group: {n_required:.0f}\")\n\n# ANOVA: What n is needed to detect f = 0.25?\nanova_power = FTestAnovaPower()\nn_per_group = anova_power.solve_power(\n    effect_size=0.25,\n    ngroups=3,\n    alpha=0.05,\n    power=0.80\n)\nprint(f\"Required n per group: {n_per_group:.0f}\")\n```\n\n### Sensitivity Analysis (Post-Study)\n\nDetermine what effect size you could detect:\n\n```python\n# With n=50 per group, what effect could we detect?\ndetectable_d = tt_ind_solve_power(\n    effect_size=None,  # Solve for this\n    nobs1=50,\n    alpha=0.05,\n    power=0.80,\n    ratio=1.0,\n    alternative='two-sided'\n)\nprint(f\"Study could detect d ≥ {detectable_d:.2f}\")\n```\n\n**Note**: Post-hoc power analysis (calculating power after study) is generally not recommended. Use sensitivity analysis instead.\n\nSee `references\u002Feffect_sizes_and_power.md` for detailed guidance.\n\n---\n\n## Reporting Results\n\n### APA Style Statistical Reporting\n\nFollow guidelines in `references\u002Freporting_standards.md`.\n\n### Essential Reporting Elements\n\n1. **Descriptive statistics**: M, SD, n for all groups\u002Fvariables\n2. **Test statistics**: Test name, statistic, df, exact p-value\n3. **Effect sizes**: With confidence intervals\n4. **Assumption checks**: Which tests were done, results, actions taken\n5. **All planned analyses**: Including non-significant findings\n\n### Example Report Templates\n\n#### Independent T-Test\n\n```\nGroup A (n = 48, M = 75.2, SD = 8.5) scored significantly higher than\nGroup B (n = 52, M = 68.3, SD = 9.2), t(98) = 3.82, p \u003C .001, d = 0.77,\n95% CI [0.36, 1.18], two-tailed. Assumptions of normality (Shapiro-Wilk:\nGroup A W = 0.97, p = .18; Group B W = 0.96, p = .12) and homogeneity\nof variance (Levene's F(1, 98) = 1.23, p = .27) were satisfied.\n```\n\n#### One-Way ANOVA\n\n```\nA one-way ANOVA revealed a significant main effect of treatment condition\non test scores, F(2, 147) = 8.45, p \u003C .001, η²_p = .10. Post hoc\ncomparisons using Tukey's HSD indicated that Condition A (M = 78.2,\nSD = 7.3) scored significantly higher than Condition B (M = 71.5,\nSD = 8.1, p = .002, d = 0.87) and Condition C (M = 70.1, SD = 7.9,\np \u003C .001, d = 1.07). Conditions B and C did not differ significantly\n(p = .52, d = 0.18).\n```\n\n#### Multiple Regression\n\n```\nMultiple linear regression was conducted to predict exam scores from\nstudy hours, prior GPA, and attendance. The overall model was significant,\nF(3, 146) = 45.2, p \u003C .001, R² = .48, adjusted R² = .47. Study hours\n(B = 1.80, SE = 0.31, β = .35, t = 5.78, p \u003C .001, 95% CI [1.18, 2.42])\nand prior GPA (B = 8.52, SE = 1.95, β = .28, t = 4.37, p \u003C .001,\n95% CI [4.66, 12.38]) were significant predictors, while attendance was\nnot (B = 0.15, SE = 0.12, β = .08, t = 1.25, p = .21, 95% CI [-0.09, 0.39]).\nMulticollinearity was not a concern (all VIF \u003C 1.5).\n```\n\n#### Bayesian Analysis\n\n```\nA Bayesian independent samples t-test was conducted using weakly\ninformative priors (Normal(0, 1) for mean difference). The posterior\ndistribution indicated that Group A scored higher than Group B\n(M_diff = 6.8, 95% credible interval [3.2, 10.4]). The Bayes Factor\nBF₁₀ = 45.3 provided very strong evidence for a difference between\ngroups, with a 99.8% posterior probability that Group A's mean exceeded\nGroup B's mean. Convergence diagnostics were satisfactory (all R̂ \u003C 1.01,\nESS > 1000).\n```\n\n---\n\n## Bayesian Statistics\n\n### When to Use Bayesian Methods\n\nConsider Bayesian approaches when:\n- You have prior information to incorporate\n- You want direct probability statements about hypotheses\n- Sample size is small or planning sequential data collection\n- You need to quantify evidence for the null hypothesis\n- The model is complex (hierarchical, missing data)\n\nSee `references\u002Fbayesian_statistics.md` for comprehensive guidance on:\n- Bayes' theorem and interpretation\n- Prior specification (informative, weakly informative, non-informative)\n- Bayesian hypothesis testing with Bayes Factors\n- Credible intervals vs. confidence intervals\n- Bayesian t-tests, ANOVA, regression, and hierarchical models\n- Model convergence checking and posterior predictive checks\n\n### Key Advantages\n\n1. **Intuitive interpretation**: \"Given the data, there is a 95% probability the parameter is in this interval\"\n2. **Evidence for null**: Can quantify support for no effect\n3. **Flexible**: No p-hacking concerns; can analyze data as it arrives\n4. **Uncertainty quantification**: Full posterior distribution\n\n---\n\n## Resources\n\nThis skill includes comprehensive reference materials:\n\n### References Directory\n\n- **test_selection_guide.md**: Decision tree for choosing appropriate statistical tests\n- **assumptions_and_diagnostics.md**: Detailed guidance on checking and handling assumption violations\n- **effect_sizes_and_power.md**: Calculating, interpreting, and reporting effect sizes; conducting power analyses\n- **bayesian_statistics.md**: Complete guide to Bayesian analysis methods\n- **reporting_standards.md**: APA-style reporting guidelines with examples\n\n### Scripts Directory\n\n- **assumption_checks.py**: Automated assumption checking with visualizations\n  - `comprehensive_assumption_check()`: Complete workflow\n  - `check_normality()`: Normality testing with Q-Q plots\n  - `check_homogeneity_of_variance()`: Levene's test with box plots\n  - `check_linearity()`: Regression linearity checks\n  - `detect_outliers()`: IQR and z-score outlier detection\n\n---\n\n## Best Practices\n\n1. **Pre-register analyses** when possible to distinguish confirmatory from exploratory\n2. **Always check assumptions** before interpreting results\n3. **Report effect sizes** with confidence intervals\n4. **Report all planned analyses** including non-significant results\n5. **Distinguish statistical from practical significance**\n6. **Visualize data** before and after analysis\n7. **Check diagnostics** for regression\u002FANOVA (residual plots, VIF, etc.)\n8. **Conduct sensitivity analyses** to assess robustness\n9. **Share data and code** for reproducibility\n10. **Be transparent** about violations, transformations, and decisions\n\n---\n\n## Common Pitfalls to Avoid\n\n1. **P-hacking**: Don't test multiple ways until something is significant\n2. **HARKing**: Don't present exploratory findings as confirmatory\n3. **Ignoring assumptions**: Check them and report violations\n4. **Confusing significance with importance**: p \u003C .05 ≠ meaningful effect\n5. **Not reporting effect sizes**: Essential for interpretation\n6. **Cherry-picking results**: Report all planned analyses\n7. **Misinterpreting p-values**: They're NOT probability that hypothesis is true\n8. **Multiple comparisons**: Correct for family-wise error when appropriate\n9. **Ignoring missing data**: Understand mechanism (MCAR, MAR, MNAR)\n10. **Overinterpreting non-significant results**: Absence of evidence ≠ evidence of absence\n\n---\n\n## Getting Started Checklist\n\nWhen beginning a statistical analysis:\n\n- [ ] Define research question and hypotheses\n- [ ] Determine appropriate statistical test (use test_selection_guide.md)\n- [ ] Conduct power analysis to determine sample size\n- [ ] Load and inspect data\n- [ ] Check for missing data and outliers\n- [ ] Verify assumptions using assumption_checks.py\n- [ ] Run primary analysis\n- [ ] Calculate effect sizes with confidence intervals\n- [ ] Conduct post-hoc tests if needed (with corrections)\n- [ ] Create visualizations\n- [ ] Write results following reporting_standards.md\n- [ ] Conduct sensitivity analyses\n- [ ] Share data and code\n\n---\n\n## Support and Further Reading\n\nFor questions about:\n- **Test selection**: See references\u002Ftest_selection_guide.md\n- **Assumptions**: See references\u002Fassumptions_and_diagnostics.md\n- **Effect sizes**: See references\u002Feffect_sizes_and_power.md\n- **Bayesian methods**: See references\u002Fbayesian_statistics.md\n- **Reporting**: See references\u002Freporting_standards.md\n\n**Key textbooks**:\n- Cohen, J. (1988). *Statistical Power Analysis for the Behavioral Sciences*\n- Field, A. (2013). *Discovering Statistics Using IBM SPSS Statistics*\n- Gelman, A., & Hill, J. (2006). *Data Analysis Using Regression and Multilevel\u002FHierarchical Models*\n- Kruschke, J. K. (2014). *Doing Bayesian Data Analysis*\n\n**Online resources**:\n- APA Style Guide: https:\u002F\u002Fapastyle.apa.org\u002F\n- Statistical Consulting: Cross Validated (stats.stackexchange.com)\n\n","# Statistical Analysis\n\n## Overview\n\nStatistical analysis is a systematic process for testing hypotheses and quantifying relationships. Conduct hypothesis tests (t-test, ANOVA, chi-square), regression, correlation, and Bayesian analyses with assumption checks and APA reporting. Apply this skill for academic research.\n\n## When to Use This Skill\n\nThis skill should be used when:\n- Conducting statistical hypothesis tests (t-tests, ANOVA, chi-square)\n- Performing regression or correlation analyses\n- Running Bayesian statistical analyses\n- Checking statistical assumptions and diagnostics\n- Calculating effect sizes and conducting power analyses\n- Reporting statistical results in APA format\n- Analyzing experimental or observational data for research\n\n---\n\n## Core Capabilities\n\n### 1. Test Selection and Planning\n- Choose appropriate statistical tests based on research questions and data characteristics\n- Conduct a priori power analyses to determine required sample sizes\n- Plan analysis strategies including multiple comparison corrections\n\n### 2. Assumption Checking\n- Automatically verify all relevant assumptions before running tests\n- Provide diagnostic visualizations (Q-Q plots, residual plots, box plots)\n- Recommend remedial actions when assumptions are violated\n\n### 3. Statistical Testing\n- Hypothesis testing: t-tests, ANOVA, chi-square, non-parametric alternatives\n- Regression: linear, multiple, logistic, with diagnostics\n- Correlations: Pearson, Spearman, with confidence intervals\n- Bayesian alternatives: Bayesian t-tests, ANOVA, regression with Bayes Factors\n\n### 4. Effect Sizes and Interpretation\n- Calculate and interpret appropriate effect sizes for all analyses\n- Provide confidence intervals for effect estimates\n- Distinguish statistical from practical significance\n\n### 5. Professional Reporting\n- Generate APA-style statistical reports\n- Create publication-ready figures and tables\n- Provide complete interpretation with all required statistics\n\n---\n\n## Workflow Decision Tree\n\nUse this decision tree to determine your analysis path:\n\n```\nSTART\n│\n├─ Need to SELECT a statistical test?\n│  └─ YES → See \"Test Selection Guide\"\n│  └─ NO → Continue\n│\n├─ Ready to check ASSUMPTIONS?\n│  └─ YES → See \"Assumption Checking\"\n│  └─ NO → Continue\n│\n├─ Ready to run ANALYSIS?\n│  └─ YES → See \"Running Statistical Tests\"\n│  └─ NO → Continue\n│\n└─ Need to REPORT results?\n   └─ YES → See \"Reporting Results\"\n```\n\n---\n\n## Test Selection Guide\n\n### Quick Reference: Choosing the Right Test\n\nUse `references\u002Ftest_selection_guide.md` for comprehensive guidance. Quick reference:\n\n**Comparing Two Groups:**\n- Independent, continuous, normal → Independent t-test\n- Independent, continuous, non-normal → Mann-Whitney U test\n- Paired, continuous, normal → Paired t-test\n- Paired, continuous, non-normal → Wilcoxon signed-rank test\n- Binary outcome → Chi-square or Fisher's exact test\n\n**Comparing 3+ Groups:**\n- Independent, continuous, normal → One-way ANOVA\n- Independent, continuous, non-normal → Kruskal-Wallis test\n- Paired, continuous, normal → Repeated measures ANOVA\n- Paired, continuous, non-normal → Friedman test\n\n**Relationships:**\n- Two continuous variables → Pearson (normal) or Spearman correlation (non-normal)\n- Continuous outcome with predictor(s) → Linear regression\n- Binary outcome with predictor(s) → Logistic regression\n\n**Bayesian Alternatives:**\nAll tests have Bayesian versions that provide:\n- Direct probability statements about hypotheses\n- Bayes Factors quantifying evidence\n- Ability to support null hypothesis\n- See `references\u002Fbayesian_statistics.md`\n\n---\n\n## Assumption Checking\n\n### Systematic Assumption Verification\n\n**ALWAYS check assumptions before interpreting test results.**\n\nUse the provided `scripts\u002Fassumption_checks.py` module for automated checking:\n\n```python\nfrom scripts.assumption_checks import comprehensive_assumption_check\n\n# Comprehensive check with visualizations\nresults = comprehensive_assumption_check(\n    data=df,\n    value_col='score',\n    group_col='group',  # Optional: for group comparisons\n    alpha=0.05\n)\n```\n\nThis performs:\n1. **Outlier detection** (IQR and z-score methods)\n2. **Normality testing** (Shapiro-Wilk test + Q-Q plots)\n3. **Homogeneity of variance** (Levene's test + box plots)\n4. **Interpretation and recommendations**\n\n### Individual Assumption Checks\n\nFor targeted checks, use individual functions:\n\n```python\nfrom scripts.assumption_checks import (\n    check_normality,\n    check_normality_per_group,\n    check_homogeneity_of_variance,\n    check_linearity,\n    detect_outliers\n)\n\n# Example: Check normality with visualization\nresult = check_normality(\n    data=df['score'],\n    name='Test Score',\n    alpha=0.05,\n    plot=True\n)\nprint(result['interpretation'])\nprint(result['recommendation'])\n```\n\n### What to Do When Assumptions Are Violated\n\n**Normality violated:**\n- Mild violation + n > 30 per group → Proceed with parametric test (robust)\n- Moderate violation → Use non-parametric alternative\n- Severe violation → Transform data or use non-parametric test\n\n**Homogeneity of variance violated:**\n- For t-test → Use Welch's t-test\n- For ANOVA → Use Welch's ANOVA or Brown-Forsythe ANOVA\n- For regression → Use robust standard errors or weighted least squares\n\n**Linearity violated (regression):**\n- Add polynomial terms\n- Transform variables\n- Use non-linear models or GAM\n\nSee `references\u002Fassumptions_and_diagnostics.md` for comprehensive guidance.\n\n---\n\n## Running Statistical Tests\n\n### Python Libraries\n\nPrimary libraries for statistical analysis:\n- **scipy.stats**: Core statistical tests\n- **statsmodels**: Advanced regression and diagnostics\n- **pingouin**: User-friendly statistical testing with effect sizes\n- **pymc**: Bayesian statistical modeling\n- **arviz**: Bayesian visualization and diagnostics\n\n### Example Analyses\n\n#### T-Test with Complete Reporting\n\n```python\nimport pingouin as pg\nimport numpy as np\n\n# Run independent t-test\nresult = pg.ttest(group_a, group_b, correction='auto')\n\n# Extract results\nt_stat = result['T'].values[0]\ndf = result['dof'].values[0]\np_value = result['p-val'].values[0]\ncohens_d = result['cohen-d'].values[0]\nci_lower = result['CI95%'].values[0][0]\nci_upper = result['CI95%'].values[0][1]\n\n# Report\nprint(f\"t({df:.0f}) = {t_stat:.2f}, p = {p_value:.3f}\")\nprint(f\"Cohen's d = {cohens_d:.2f}, 95% CI [{ci_lower:.2f}, {ci_upper:.2f}]\")\n```\n\n#### ANOVA with Post-Hoc Tests\n\n```python\nimport pingouin as pg\n\n# One-way ANOVA\naov = pg.anova(dv='score', between='group', data=df, detailed=True)\nprint(aov)\n\n# If significant, conduct post-hoc tests\nif aov['p-unc'].values[0] \u003C 0.05:\n    posthoc = pg.pairwise_tukey(dv='score', between='group', data=df)\n    print(posthoc)\n\n# Effect size\neta_squared = aov['np2'].values[0]  # Partial eta-squared\nprint(f\"Partial η² = {eta_squared:.3f}\")\n```\n\n#### Linear Regression with Diagnostics\n\n```python\nimport statsmodels.api as sm\nfrom statsmodels.stats.outliers_influence import variance_inflation_factor\n\n# Fit model\nX = sm.add_constant(X_predictors)  # Add intercept\nmodel = sm.OLS(y, X).fit()\n\n# Summary\nprint(model.summary())\n\n# Check multicollinearity (VIF)\nvif_data = pd.DataFrame()\nvif_data[\"Variable\"] = X.columns\nvif_data[\"VIF\"] = [variance_inflation_factor(X.values, i) for i in range(X.shape[1])]\nprint(vif_data)\n\n# Check assumptions\nresiduals = model.resid\nfitted = model.fittedvalues\n\n# Residual plots\nimport matplotlib.pyplot as plt\nfig, axes = plt.subplots(2, 2, figsize=(12, 10))\n\n# Residuals vs fitted\naxes[0, 0].scatter(fitted, residuals, alpha=0.6)\naxes[0, 0].axhline(y=0, color='r', linestyle='--')\naxes[0, 0].set_xlabel('Fitted values')\naxes[0, 0].set_ylabel('Residuals')\naxes[0, 0].set_title('Residuals vs Fitted')\n\n# Q-Q plot\nfrom scipy import stats\nstats.probplot(residuals, dist=\"norm\", plot=axes[0, 1])\naxes[0, 1].set_title('Normal Q-Q')\n\n# Scale-Location\naxes[1, 0].scatter(fitted, np.sqrt(np.abs(residuals \u002F residuals.std())), alpha=0.6)\naxes[1, 0].set_xlabel('Fitted values')\naxes[1, 0].set_ylabel('√|Standardized residuals|')\naxes[1, 0].set_title('Scale-Location')\n\n# Residuals histogram\naxes[1, 1].hist(residuals, bins=20, edgecolor='black', alpha=0.7)\naxes[1, 1].set_xlabel('Residuals')\naxes[1, 1].set_ylabel('Frequency')\naxes[1, 1].set_title('Histogram of Residuals')\n\nplt.tight_layout()\nplt.show()\n```\n\n#### Bayesian T-Test\n\n```python\nimport pymc as pm\nimport arviz as az\nimport numpy as np\n\nwith pm.Model() as model:\n    # Priors\n    mu1 = pm.Normal('mu_group1', mu=0, sigma=10)\n    mu2 = pm.Normal('mu_group2', mu=0, sigma=10)\n    sigma = pm.HalfNormal('sigma', sigma=10)\n\n    # Likelihood\n    y1 = pm.Normal('y1', mu=mu1, sigma=sigma, observed=group_a)\n    y2 = pm.Normal('y2', mu=mu2, sigma=sigma, observed=group_b)\n\n    # Derived quantity\n    diff = pm.Deterministic('difference', mu1 - mu2)\n\n    # Sample\n    trace = pm.sample(2000, tune=1000, return_inferencedata=True)\n\n# Summarize\nprint(az.summary(trace, var_names=['difference']))\n\n# Probability that group1 > group2\nprob_greater = np.mean(trace.posterior['difference'].values > 0)\nprint(f\"P(μ₁ > μ₂ | data) = {prob_greater:.3f}\")\n\n# Plot posterior\naz.plot_posterior(trace, var_names=['difference'], ref_val=0)\n```\n\n---\n\n## Effect Sizes\n\n### Always Calculate Effect Sizes\n\n**Effect sizes quantify magnitude, while p-values only indicate existence of an effect.**\n\nSee `references\u002Feffect_sizes_and_power.md` for comprehensive guidance.\n\n### Quick Reference: Common Effect Sizes\n\n| Test | Effect Size | Small | Medium | Large |\n|------|-------------|-------|--------|-------|\n| T-test | Cohen's d | 0.20 | 0.50 | 0.80 |\n| ANOVA | η²_p | 0.01 | 0.06 | 0.14 |\n| Correlation | r | 0.10 | 0.30 | 0.50 |\n| Regression | R² | 0.02 | 0.13 | 0.26 |\n| Chi-square | Cramér's V | 0.07 | 0.21 | 0.35 |\n\n**Important**: Benchmarks are guidelines. Context matters!\n\n### Calculating Effect Sizes\n\nMost effect sizes are automatically calculated by pingouin:\n\n```python\n# T-test returns Cohen's d\nresult = pg.ttest(x, y)\nd = result['cohen-d'].values[0]\n\n# ANOVA returns partial eta-squared\naov = pg.anova(dv='score', between='group', data=df)\neta_p2 = aov['np2'].values[0]\n\n# Correlation: r is already an effect size\ncorr = pg.corr(x, y)\nr = corr['r'].values[0]\n```\n\n### Confidence Intervals for Effect Sizes\n\nAlways report CIs to show precision:\n\n```python\nfrom pingouin import compute_effsize_from_t\n\n# For t-test\nd, ci = compute_effsize_from_t(\n    t_statistic,\n    nx=len(group1),\n    ny=len(group2),\n    eftype='cohen'\n)\nprint(f\"d = {d:.2f}, 95% CI [{ci[0]:.2f}, {ci[1]:.2f}]\")\n```\n\n---\n\n## Power Analysis\n\n### A Priori Power Analysis (Study Planning)\n\nDetermine required sample size before data collection:\n\n```python\nfrom statsmodels.stats.power import (\n    tt_ind_solve_power,\n    FTestAnovaPower\n)\n\n# T-test: What n is needed to detect d = 0.5?\nn_required = tt_ind_solve_power(\n    effect_size=0.5,\n    alpha=0.05,\n    power=0.80,\n    ratio=1.0,\n    alternative='two-sided'\n)\nprint(f\"Required n per group: {n_required:.0f}\")\n\n# ANOVA: What n is needed to detect f = 0.25?\nanova_power = FTestAnovaPower()\nn_per_group = anova_power.solve_power(\n    effect_size=0.25,\n    ngroups=3,\n    alpha=0.05,\n    power=0.80\n)\nprint(f\"Required n per group: {n_per_group:.0f}\")\n```\n\n### Sensitivity Analysis (Post-Study)\n\nDetermine what effect size you could detect:\n\n```python\n# With n=50 per group, what effect could we detect?\ndetectable_d = tt_ind_solve_power(\n    effect_size=None,  # Solve for this\n    nobs1=50,\n    alpha=0.05,\n    power=0.80,\n    ratio=1.0,\n    alternative='two-sided'\n)\nprint(f\"Study could detect d ≥ {detectable_d:.2f}\")\n```\n\n**Note**: Post-hoc power analysis (calculating power after study) is generally not recommended. Use sensitivity analysis instead.\n\nSee `references\u002Feffect_sizes_and_power.md` for detailed guidance.\n\n---\n\n## Reporting Results\n\n### APA Style Statistical Reporting\n\nFollow guidelines in `references\u002Freporting_standards.md`.\n\n### Essential Reporting Elements\n\n1. **Descriptive statistics**: M, SD, n for all groups\u002Fvariables\n2. **Test statistics**: Test name, statistic, df, exact p-value\n3. **Effect sizes**: With confidence intervals\n4. **Assumption checks**: Which tests were done, results, actions taken\n5. **All planned analyses**: Including non-significant findings\n\n### Example Report Templates\n\n#### Independent T-Test\n\n```\nGroup A (n = 48, M = 75.2, SD = 8.5) scored significantly higher than\nGroup B (n = 52, M = 68.3, SD = 9.2), t(98) = 3.82, p \u003C .001, d = 0.77,\n95% CI [0.36, 1.18], two-tailed. Assumptions of normality (Shapiro-Wilk:\nGroup A W = 0.97, p = .18; Group B W = 0.96, p = .12) and homogeneity\nof variance (Levene's F(1, 98) = 1.23, p = .27) were satisfied.\n```\n\n#### One-Way ANOVA\n\n```\nA one-way ANOVA revealed a significant main effect of treatment condition\non test scores, F(2, 147) = 8.45, p \u003C .001, η²_p = .10. Post hoc\ncomparisons using Tukey's HSD indicated that Condition A (M = 78.2,\nSD = 7.3) scored significantly higher than Condition B (M = 71.5,\nSD = 8.1, p = .002, d = 0.87) and Condition C (M = 70.1, SD = 7.9,\np \u003C .001, d = 1.07). Conditions B and C did not differ significantly\n(p = .52, d = 0.18).\n```\n\n#### Multiple Regression\n\n```\nMultiple linear regression was conducted to predict exam scores from\nstudy hours, prior GPA, and attendance. The overall model was significant,\nF(3, 146) = 45.2, p \u003C .001, R² = .48, adjusted R² = .47. Study hours\n(B = 1.80, SE = 0.31, β = .35, t = 5.78, p \u003C .001, 95% CI [1.18, 2.42])\nand prior GPA (B = 8.52, SE = 1.95, β = .28, t = 4.37, p \u003C .001,\n95% CI [4.66, 12.38]) were significant predictors, while attendance was\nnot (B = 0.15, SE = 0.12, β = .08, t = 1.25, p = .21, 95% CI [-0.09, 0.39]).\nMulticollinearity was not a concern (all VIF \u003C 1.5).\n```\n\n#### Bayesian Analysis\n\n```\nA Bayesian independent samples t-test was conducted using weakly\ninformative priors (Normal(0, 1) for mean difference). The posterior\ndistribution indicated that Group A scored higher than Group B\n(M_diff = 6.8, 95% credible interval [3.2, 10.4]). The Bayes Factor\nBF₁₀ = 45.3 provided very strong evidence for a difference between\ngroups, with a 99.8% posterior probability that Group A's mean exceeded\nGroup B's mean. Convergence diagnostics were satisfactory (all R̂ \u003C 1.01,\nESS > 1000).\n```\n\n---\n\n## Bayesian Statistics\n\n### When to Use Bayesian Methods\n\nConsider Bayesian approaches when:\n- You have prior information to incorporate\n- You want direct probability statements about hypotheses\n- Sample size is small or planning sequential data collection\n- You need to quantify evidence for the null hypothesis\n- The model is complex (hierarchical, missing data)\n\nSee `references\u002Fbayesian_statistics.md` for comprehensive guidance on:\n- Bayes' theorem and interpretation\n- Prior specification (informative, weakly informative, non-informative)\n- Bayesian hypothesis testing with Bayes Factors\n- Credible intervals vs. confidence intervals\n- Bayesian t-tests, ANOVA, regression, and hierarchical models\n- Model convergence checking and posterior predictive checks\n\n### Key Advantages\n\n1. **Intuitive interpretation**: \"Given the data, there is a 95% probability the parameter is in this interval\"\n2. **Evidence for null**: Can quantify support for no effect\n3. **Flexible**: No p-hacking concerns; can analyze data as it arrives\n4. **Uncertainty quantification**: Full posterior distribution\n\n---\n\n## Resources\n\nThis skill includes comprehensive reference materials:\n\n### References Directory\n\n- **test_selection_guide.md**: Decision tree for choosing appropriate statistical tests\n- **assumptions_and_diagnostics.md**: Detailed guidance on checking and handling assumption violations\n- **effect_sizes_and_power.md**: Calculating, interpreting, and reporting effect sizes; conducting power analyses\n- **bayesian_statistics.md**: Complete guide to Bayesian analysis methods\n- **reporting_standards.md**: APA-style reporting guidelines with examples\n\n### Scripts Directory\n\n- **assumption_checks.py**: Automated assumption checking with visualizations\n  - `comprehensive_assumption_check()`: Complete workflow\n  - `check_normality()`: Normality testing with Q-Q plots\n  - `check_homogeneity_of_variance()`: Levene's test with box plots\n  - `check_linearity()`: Regression linearity checks\n  - `detect_outliers()`: IQR and z-score outlier detection\n\n---\n\n## Best Practices\n\n1. **Pre-register analyses** when possible to distinguish confirmatory from exploratory\n2. **Always check assumptions** before interpreting results\n3. **Report effect sizes** with confidence intervals\n4. **Report all planned analyses** including non-significant results\n5. **Distinguish statistical from practical significance**\n6. **Visualize data** before and after analysis\n7. **Check diagnostics** for regression\u002FANOVA (residual plots, VIF, etc.)\n8. **Conduct sensitivity analyses** to assess robustness\n9. **Share data and code** for reproducibility\n10. **Be transparent** about violations, transformations, and decisions\n\n---\n\n## Common Pitfalls to Avoid\n\n1. **P-hacking**: Don't test multiple ways until something is significant\n2. **HARKing**: Don't present exploratory findings as confirmatory\n3. **Ignoring assumptions**: Check them and report violations\n4. **Confusing significance with importance**: p \u003C .05 ≠ meaningful effect\n5. **Not reporting effect sizes**: Essential for interpretation\n6. **Cherry-picking results**: Report all planned analyses\n7. **Misinterpreting p-values**: They're NOT probability that hypothesis is true\n8. **Multiple comparisons**: Correct for family-wise error when appropriate\n9. **Ignoring missing data**: Understand mechanism (MCAR, MAR, MNAR)\n10. **Overinterpreting non-significant results**: Absence of evidence ≠ evidence of absence\n\n---\n\n## Getting Started Checklist\n\nWhen beginning a statistical analysis:\n\n- [ ] Define research question and hypotheses\n- [ ] Determine appropriate statistical test (use test_selection_guide.md)\n- [ ] Conduct power analysis to determine sample size\n- [ ] Load and inspect data\n- [ ] Check for missing data and outliers\n- [ ] Verify assumptions using assumption_checks.py\n- [ ] Run primary analysis\n- [ ] Calculate effect sizes with confidence intervals\n- [ ] Conduct post-hoc tests if needed (with corrections)\n- [ ] Create visualizations\n- [ ] Write results following reporting_standards.md\n- [ ] Conduct sensitivity analyses\n- [ ] Share data and code\n\n---\n\n## Support and Further Reading\n\nFor questions about:\n- **Test selection**: See references\u002Ftest_selection_guide.md\n- **Assumptions**: See references\u002Fassumptions_and_diagnostics.md\n- **Effect sizes**: See references\u002Feffect_sizes_and_power.md\n- **Bayesian methods**: See references\u002Fbayesian_statistics.md\n- **Reporting**: See references\u002Freporting_standards.md\n\n**Key textbooks**:\n- Cohen, J. (1988). *Statistical Power Analysis for the Behavioral Sciences*\n- Field, A. (2013). *Discovering Statistics Using IBM SPSS Statistics*\n- Gelman, A., & Hill, J. (2006). *Data Analysis Using Regression and Multilevel\u002FHierarchical Models*\n- Kruschke, J. K. (2014). *Doing Bayesian Data Analysis*\n\n**Online resources**:\n- APA Style Guide: https:\u002F\u002Fapastyle.apa.org\u002F\n- Statistical Consulting: Cross Validated (stats.stackexchange.com)\n\n",{"name":5,"license":49,"category":39,"metadata":50,"description":7},"MIT license",{"skill-author":51},"Synthetic Sciences","main","4aa39efd1cdab0b4657ecee16c92a92011a5b10f","openscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub","https:\u002F\u002Fgithub.com\u002Ffadrienne","2026-10-28 00:43:09",{"source":8,"skillName":5,"commands":59,"prompt":69,"zipAvailable":70},[60,63,66],{"tool":61,"command":62},"npx","npx skills add fadrienne\u002FMyGitHub --skill statistical-analysis",{"tool":64,"command":65},"bunx","bunx skills add fadrienne\u002FMyGitHub --skill statistical-analysis",{"tool":67,"command":68},"pnpm","pnpm dlx skills add fadrienne\u002FMyGitHub --skill statistical-analysis","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002FSKILL.md",true,[72,78,82,86,90,94],{"path":73,"resourceType":74,"resourceTypeDesc":75,"sizeBytes":76,"sourceHtmlUrl":77},"references\u002Fassumptions_and_diagnostics.md","REFERENCE","参考文档",11139,"https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002Freferences\u002Fassumptions_and_diagnostics.md",{"path":79,"resourceType":74,"resourceTypeDesc":75,"sizeBytes":80,"sourceHtmlUrl":81},"references\u002Fbayesian_statistics.md",17533,"https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002Freferences\u002Fbayesian_statistics.md",{"path":83,"resourceType":74,"resourceTypeDesc":75,"sizeBytes":84,"sourceHtmlUrl":85},"references\u002Feffect_sizes_and_power.md",14989,"https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002Freferences\u002Feffect_sizes_and_power.md",{"path":87,"resourceType":74,"resourceTypeDesc":75,"sizeBytes":88,"sourceHtmlUrl":89},"references\u002Freporting_standards.md",19504,"https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002Freferences\u002Freporting_standards.md",{"path":91,"resourceType":74,"resourceTypeDesc":75,"sizeBytes":92,"sourceHtmlUrl":93},"references\u002Ftest_selection_guide.md",5077,"https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002Freferences\u002Ftest_selection_guide.md",{"path":95,"resourceType":96,"resourceTypeDesc":97,"sizeBytes":98,"sourceHtmlUrl":99},"scripts\u002Fassumption_checks.py","SCRIPT","脚本",15859,"https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fopenscience\u002Fbackend\u002Fcli\u002Fskills\u002Fcoding\u002Fstatistical-analysis\u002Fscripts\u002Fassumption_checks.py",[101,128,136,170,197,224],{"skillNo":102,"name":103,"nameZh":6,"description":104,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":105,"categories":106,"keywords":110,"publishedAt":44},"01M7167B28PK20HP7R7ZED2DY0","statistical-power","Sample size calculation, power analysis, and effect size conversion for scientific studies. Use BEFORE data collection (a priori) to determine required N, or after (post-hoc) to compute achieved power. Covers parametric tests (t-test, ANOVA, chi-square, proportions, correlation, regression), simulation-based power for complex\u002Fclustered\u002Fnested designs, and power curves. Use this skill when someone asks 'how many samples do I need', 'what is my power', 'what effect size can I detect', or any variant. Pairs with \u002Fexperimental-design (choose design first, then compute power) and \u002Fstatistical-analysis (analyze data after collection).","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fscientific-agent-skills\u002Fskills\u002Fstatistical-power\u002FSKILL.md",[107],{"categoryNo":108,"categoryName":109,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发",[26,111,112,113,114,115,116,117,27,118,119,24,120,121,122,123,124,125,126,127],"statistical power","effect","scipy","regression","choose","design","uv","Bash","collection","calculation","ANOVA","conversion","analyze","t-test","chi-square","simulation","sample",{"skillNo":129,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":130,"categories":131,"keywords":133,"publishedAt":44},"01M71677EBCM8EPCE9BZCK8505","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fscientific-agent-skills\u002Fskills\u002Fstatistical-analysis\u002FSKILL.md",[132],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[24,25,26,28,30,35,27,31,42,41,29,34,37,32,43,36,38,40,134,135],"models","help",{"skillNo":137,"name":138,"nameZh":6,"description":139,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":140,"categories":141,"keywords":151,"publishedAt":44},"01M71673R93XAHFH81DBNVNG7H","scientific-writing","Core skill for the deep research and writing tool. Write scientific manuscripts in full paragraphs (never bullet points). Use two-stage process with (1) section outlines with key points using research-lookup then (2) convert to flowing prose. IMRAD structure, citations (APA\u002FAMA\u002FVancouver), figures\u002Ftables, reporting guidelines (CONSORT\u002FSTROBE\u002FPRISMA), for research papers and journal submissions.","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fscientific-agent-skills\u002Fskills\u002Fscientific-writing\u002FSKILL.md",[142,145,146],{"categoryNo":143,"categoryName":144,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000018","写作与文案",{"categoryNo":108,"categoryName":109,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":147,"categoryName":148,"taxonomyType":149,"taxonomyTypeDesc":150},"01JBSEEDCAT000000000000036","内容创作者","PROFESSION","适用职业",[152,153,154,155,156,157,158,159,160,161,118,162,163,164,165,166,167,168,42,169],"writing","scientific","scientific writing","Citations","deep","deep research","never","papers","journal","false","api","prisma","structure","openrouter","Outlines","core skill","read","features",{"skillNo":171,"name":172,"nameZh":6,"description":173,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":174,"categories":175,"keywords":180,"publishedAt":44},"01M7166ZPKXBF4EBPHVTJPQBB1","scientific-visualization","Meta-skill for publication-ready figures. Use when creating journal submission figures requiring multi-panel layouts, significance annotations, error bars, colorblind-safe palettes, and specific journal formatting (Nature, Science, Cell). Orchestrates matplotlib\u002Fseaborn\u002Fplotly with publication styles. For quick exploration use seaborn or plotly directly.","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fscientific-agent-skills\u002Fskills\u002Fscientific-visualization\u002FSKILL.md",[176,179],{"categoryNo":177,"categoryName":178,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000013","分析与可视化",{"categoryNo":108,"categoryName":109,"taxonomyType":21,"taxonomyTypeDesc":22},[181,153,182,183,184,185,186,187,188,160,27,189,190,191,192,193,194,195,29,196],"visualization","scientific visualization","error","ready","quick","exploration","meta-skill","Meta","safe","plotly","annotations","formatting","Publication","figures","panel","submission",{"skillNo":198,"name":199,"nameZh":6,"description":200,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":201,"categories":202,"keywords":209,"publishedAt":44},"01M7166VXJWQSSC3RQZP60WBGR","research-code","Debug, profile, review, and restructure Python research and analysis code. Use when analysis scripts crash, produce wrong results, run too slowly, or need a correctness review. Covers: reading tracebacks and diagnosing root causes, hypothesis-driven debugging, reviewing code for common statistical\u002Fnumerical errors, profiling data pipelines, improving reproducibility (seeds, environments, determinism), and structuring analysis scripts for sharing. Distinct from \u002Fexploratory-data-analysis (which understands data) and \u002Fstatistical-analysis (which chooses and runs tests) — this skill focuses on the code itself.","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fscientific-agent-skills\u002Fskills\u002Fresearch-code\u002FSKILL.md",[203,206],{"categoryNo":204,"categoryName":205,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000021","资料检索与研究",{"categoryNo":207,"categoryName":208,"taxonomyType":149,"taxonomyTypeDesc":150},"01JBSEEDCAT000000000000030","开发工程师",[210,211,36,212,213,214,215,117,216,27,118,24,217,218,219,220,221,222,168,223],"code","research code","which","memory","data-analysis","errors","debugging","common","review","data pipelines","run","scripts","line","write",{"skillNo":225,"name":226,"nameZh":6,"description":227,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":228,"licenseFileUrl":6,"sourceHtmlUrl":229,"categories":230,"keywords":237,"publishedAt":44},"01M7166CF5HSR7SVZYZFWTDX55","markdown-mermaid-writing","Comprehensive markdown and Mermaid diagram writing skill. Use when creating any scientific document, report, analysis, or visualization. Establishes text-based diagrams as the default documentation standard with full style guides (markdown + mermaid), 24 diagram type references, and 9 document templates.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Ffadrienne\u002FMyGitHub\u002Fblob\u002Fmain\u002Fscientific-agent-skills\u002Fskills\u002Fmarkdown-mermaid-writing\u002FSKILL.md",[231,234,235,236],{"categoryNo":232,"categoryName":233,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000002","文档处理",{"categoryNo":143,"categoryName":144,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":108,"categoryName":109,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":147,"categoryName":148,"taxonomyType":149,"taxonomyTypeDesc":150},[152,238,239,240,241,242,181,243,244,27,118,24,245,246,247,248,249,250,153,168],"markdown mermaid writing","mermaid","markdown","community","diagrams","project","default","team","guides","text","documentation","references","diagram"]