A small survey, start to finish: from frequencies to regression
60 synthetic respondents · six steps — frequencies → descriptives → t-test → one-way ANOVA → correlation → regression
Research question — Does the score differ by gender or by department — and what predicts it?
Raw data walkthrough_survey.csv · 60 rows
Synthetic data — the 60-row survey built by scripts/walkthrough/make_sample.py, the same sample the guide articles and the walkthrough use. Every table and APA sentence is a measured result: backend/tests/test_en_sample_walkthrough_en2.py runs the engines in English to produce them.
| id | gender | age | department | satisfaction | score |
|---|---|---|---|---|---|
| R001 | F | 28 | Sales | 4 | 4.12 |
| R002 | M | 20 | Sales | 3 | 2.93 |
| R003 | F | 33 | Support | 2 | 1.91 |
| R004 | M | 32 | Sales | 3 | 2.46 |
| R005 | F | 46 | Support | 5 | 4.9 |
The study, step by step — what was actually produced
① Frequencies — who answered
Start by counting: how many people in each gender and each department, and whether any cell is missing. Skip this and every later test reports a result without you ever knowing how many cases it ran on.
A frequency analysis was conducted on gender and department (N = 60). For gender (2 categories), "F, M" each appeared equally often (30, 50.0% of valid cases); valid n = 60, missing = 0. For department (3 categories), the most frequent category was "Research" (24, 40.0% of valid cases); valid n = 60, missing = 0. No missing data were present.
② Descriptives — the shape of the score
Mean, standard deviation, median, quartiles, range, skewness and kurtosis for the score column. A distribution piled up on one side changes which test belongs here.
Descriptive statistics were computed for score (N = 60). For score, M = 3.75, SD = 0.77, Mdn = 3.96, range = 1.73–5.00. Skewness = -0.57 and kurtosis = -0.05, within normal range. No missing data were present.
③ Independent-samples t-test — does it differ by gender
Compare two group means. Levene’s test checks the equal-variance assumption alongside it, and the result carries an effect size (Cohen’s d) and a confidence interval for the difference.
Independent-samples t-tests compared score across levels of gender (N = 60). For score, F (M = 4.11, SD = 0.66) scored significantly higher than M (M = 3.39, SD = 0.71), Student's t(58) = 4.06, p < .001, d = 1.05, 95% CI [0.36, 1.07]. Levene's test indicated equal variances.
④ One-way ANOVA — does it differ by department
With three groups you do not run three t-tests; you run one. When the effect is significant, the post-hoc comparison (Tukey HSD) names the pair — that table is printed here too.
One-way ANOVAs examined score across levels of department (N = 60). For score, there was a non-significant effect, F(2, 57) = 1.77, p = .180, η² = .06. Levene's test indicated equal variances (p = .886). Group statistics: Research (M = 3.96, SD = 0.71), Sales (M = 3.51, SD = 0.80), Support (M = 3.70, SD = 0.79).
⑤ Correlation — what moves together
Three variables make three pairs, so the result is a matrix rather than a sentence: each cell carries r with its p.
A Pearson correlation analysis was conducted (N = 60). score and age were significantly correlated in a positive direction, r = .26, 95% CI [.01, .49], p = .041. score and satisfaction were significantly correlated in a positive direction, r = .87, 95% CI [.79, .92], p < .001.
⑥ Regression — what predicts the score
Predict score from age and satisfaction. Gender is text, so the engine leaves it out of the regression — and says so in a footnote instead of dropping it quietly.
A multiple linear regression was conducted to predict score from age, satisfaction. The overall model was significant (R² = .77, adjusted R² = .76, F(2, 57) = 93.64, p < .001). The predictors accounted for 76.7% of the variance in score. age was not a significant predictor (β = .11, p = .083). satisfaction significantly predicted score (B = 0.72, SE = 0.06, β = .85, t(57) = 13.05, p < .001). Multicollinearity was assessed using the variance inflation factor; the maximum VIF was 8.28 (age), indicating no serious multicollinearity. · Excluded variables: gender — not numeric, so they were left out.
Key results
① Frequency table
Total N = 60, Total missing = 0 · Cumulative percent: based on valid responses
| Variable | Category | Frequency | Percent | Valid Percent | Cumulative Percent |
|---|---|---|---|---|---|
| gender | F | 30 | 50.0 | 50.0 | 50.0 |
| gender | M | 30 | 50.0 | 50.0 | 100.0 |
| department | Research | 24 | 40.0 | 40.0 | 40.0 |
| department | Sales | 17 | 28.3 | 28.3 | 68.3 |
| department | Support | 19 | 31.7 | 31.7 | 100.0 |
| Total | 60 | 100.0 | 100.0 | 100.0 |
② Descriptive statistics
Total N = 60, Total missing = 0
| Variable | N | Mean | Std. Deviation | Variance | Std. Error | Median | Q1 | Q3 | Minimum | Maximum | Skewness | Kurtosis |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| score | 60 | 3.75 | 0.77 | 0.59 | 0.099 | 3.96 | 3.23 | 4.27 | 1.73 | 5.0 | -0.567 | -0.052 |
③ Mean comparison by gender
score: Levene p=.399
| Variable | Group | N | Mean | SD | Equal variances | t | df | p | Mean difference | Cohen's d | 95% CI of difference |
|---|---|---|---|---|---|---|---|---|---|---|---|
| score | F | 30 | 4.11 | 0.657 | assumed | 4.058 | 58 | < .001 | 0.718 | 1.048 | [0.364, 1.072] |
| M | 30 | 3.39 | 0.713 |
④ score — Post hoc comparisons (Tukey HSD)
| Comparison | Mean difference | Std. Error | p | 95% CI | Decision |
|---|---|---|---|---|---|
| Research vs Sales | 0.445 | 0.170 | .163 | [-0.134, 1.025] | N.S. |
| Research vs Support | 0.256 | 0.165 | .520 | [-0.305, 0.818] | N.S. |
| Sales vs Support | -0.189 | 0.179 | .737 | [-0.800, 0.421] | N.S. |
④ Mean comparison by department
score: η²=0.058, ω²=0.025, Post hoc: no significant pairs
| Variable | Group | N | Mean | SD | SS | df | MS | F | p |
|---|---|---|---|---|---|---|---|---|---|
| score | Research | 24 | 3.96 | 0.707 | 2.041 | 2 | 1.021 | 1.767 | .180 |
| Sales | 17 | 3.51 | 0.796 | ||||||
| Support | 19 | 3.70 | 0.792 | ||||||
| Within groups | 32.921 | 57 | 0.578 | ||||||
| Total | 34.963 | 59 |
⑤ Pearson correlation matrix
N = 60 (pairwise) · Each cell: r (p) · Significant correlations: score↔age(r=0.264, p=.041, positive), score↔satisfaction(r=0.868, p=< .001, positive)
| Variable | age | satisfac… | score |
|---|---|---|---|
| age | 1 | ||
| satisfaction | 0.176 (.178) | 1 | |
| score | 0.264 (.041) | 0.868 (< .001) | 1 |
⑥ Factors predicting score
Dependent variable: score · N = 60 · Model summary rows: R² and adjusted R² sit in the value column; the model F sits in the test-statistic and significance columns.
| Variable | B | SE | β | t | p | VIF |
|---|---|---|---|---|---|---|
| (Constant) | 0.774 | 0.240 | 3.227 | .002 | - | |
| age | 0.007 | 0.004 | 0.115 | 1.765 | .083 | 8.28 |
| satisfaction | 0.718 | 0.055 | 0.848 | 13.047 | < .001 | 8.28 |
| R² | 0.767 | |||||
| Adjusted R² | 0.758 | |||||
| Model F(2, 57) | 93.643 | < .001 |
Representative quotes
Every quote is a sentence that exists in the raw data (excerpt-existence check passed).
Paper-ready tables
Copying opens an editable duplicate in your workbench — this showcase stays as it is.