Statistics Technology & Digital Applications 3 — Questions and Answers
Question 1: A data scientist uses Python's pandas library and calls df.describe(). Which statistic is NOT included in the default output?
- Mean
- Standard deviation
- Median
- Mode (Correct answer)
Correct answer: Mode
df.describe() includes count, mean, std, min, 25th/50th/75th percentiles, and max — but not mode.
Question 2: When using SPSS to run an independent samples t-test, Levene's Test is automatically reported. What null hypothesis does Levene's Test evaluate?
- The group means are equal
- The group variances are equal (Correct answer)
- The sample sizes are equal
- The distributions are normal
Correct answer: The group variances are equal
Levene's Test checks the assumption of homogeneity of variance (equal variances) between groups before interpreting t-test results.
Question 3: In R's ggplot2 package, which function adds a linear regression line to a scatter plot?
- geom_line()
- geom_smooth(method='lm') (Correct answer)
- geom_bar(stat='identity')
- stat_density()
Correct answer: geom_smooth(method='lm')
geom_smooth(method='lm') fits and plots a linear model trend line with optional confidence interval shading.
Question 4: A statistician stores a large dataset in a PostgreSQL database and needs only distinct values of a categorical column 'region'. Which SQL clause achieves this?
- GROUP BY region
- SELECT DISTINCT region (Correct answer)
- HAVING COUNT(*) > 1
- ORDER BY region
Correct answer: SELECT DISTINCT region
SELECT DISTINCT eliminates duplicate values and returns each unique value in the specified column exactly once.
Question 5: Which Python library provides the chi-square test of independence via the function scipy.stats.chi2_contingency()?
- NumPy
- Pandas
- SciPy (Correct answer)
- Statsmodels
Correct answer: SciPy
SciPy's stats module contains chi2_contingency(), which computes the chi-square statistic, p-value, degrees of freedom, and expected frequencies.
Question 6: In Microsoft Excel's Data Analysis ToolPak, which tool generates a table showing regression coefficients, R-squared, and ANOVA output?
- Histogram
- Descriptive Statistics
- Regression (Correct answer)
- Correlation
Correct answer: Regression
The Regression tool in Excel's ToolPak fits a linear regression model and outputs coefficients, R², standard errors, and F-test results.
Question 7: A researcher uses Power BI to visualize survey Likert-scale responses. Which chart best shows the distribution of a 5-point scale across respondents?
- Line chart
- Stacked bar chart (Correct answer)
- Waterfall chart
- Funnel chart
Correct answer: Stacked bar chart
A stacked bar chart can show the proportion of each Likert response category, making it easy to compare distributions across groups.
A data scientist uses Python's pandas library and calls df.describe().
Which statistic is NOT included in the default output?