Skip to content
SecurityOn
Go back

E-STAT 3.0 and Basic Statistics

In “Online Surveys in KSDC DB and Data Discovery in ICPSR”, I described how to find survey data and collect responses to a new questionnaire. Here I use the demonstrations from KSDC’s advanced training to work through what to check once the data are available and which analysis fits the question. E-STAT 3.0 is the online statistics program provided by KSDC DB. KSDC DB overview

The order of the demonstrations

Playback timeDemonstration
09:55–22:28Variable roles, measurement levels and choice of analysis
22:44–37:27Describing happiness scores and comparing independent groups in the 2019 Korean values survey
37:36–45:25Frequencies, recoding, cross-tabulation and a chi-square test for trust in neighbours
45:42–54:38Correlation between annual gross national income and outbound traveller counts
54:47–1:09:36Uploading an Excel file, defining missing values and running a paired t-test
From 1:18:32Reporting methods, comparing programs and checking the data and analyses available

Check variable codes before choosing a method

The video used daily temperature and coffee sales to explain variable roles. To examine whether sales vary with temperature, temperature can be the explanatory variable and sales the outcome. Day of the week or special events could also be related to sales. The names assigned to those variables do not establish a causal relationship.

The codebook explains what the numbers mean. If 1 and 2 are labels for categories, the useful summaries are counts and proportions. Four levels of trust have an order, but treating the gaps as equal requires a separate justification. A difference in degrees Celsius represents an interval, while coffee sales are counts for which zero means that no cups were sold.

AnalysisResearch questionWhat to check first
Frequency analysisHow many respondents selected each option?Response codes and the denominator for percentages
Descriptive statisticsWhere are scores concentrated and how widely do they vary?Units, number of observations and valid range
Cross-tabulation and chi-square testHow do the distributions of two categorical variables relate?Row and column denominators, independence and expected counts
Independent-samples t-testHow large is the difference between two separate groups’ means?Group independence, variances and sample composition
Paired t-testHow much do two measurements of the same units differ on average?Alignment of the pairs and the distribution of differences
One-way ANOVADo any of several group means differ?Comparison design, assumptions and follow-up comparisons
CorrelationIn which direction do two quantitative variables vary together?Scatterplot, outliers and dependence between observations
RegressionHow is an explanatory variable related to the outcome in the specified model?Model form, assumptions and study design

The video introduced ANOVA and regression when reviewing the methods. The worked examples below follow the analyses demonstrated on screen.

Happiness scores and the independent-samples t-test

The demonstration opened a ten-point question about overall happiness in the 2019 Survey on Koreans’ Perceptions and Values. Selecting the item in Descriptive statistics gives the observation count, mean, median, standard deviation, minimum and maximum. The demonstration treated the scores as numeric and calculated a mean. When summarising an item this way, explain how the intervals between scores are interpreted and look at the distribution as well.

The mean and median can diverge in data such as income, where a few large values can pull up the mean. The mean uses the magnitude of every value. The median uses the middle position after ordering the values. If a maximum exceeds the scale’s range, check for missing-value codes or entry errors before interpreting it as an outlier.

The next step split happiness scores by the survey’s recorded sex categories. In Independent-samples t-test, happiness was the outcome and sex the grouping variable. The output presented rows with and without the equal-variance assumption. The presenter used Levene’s test to guide reading the row without that assumption. To make a research result checkable, report group counts and means, the estimated difference and confidence interval, and the form of t-test used. NIST’s guide to comparing two means

Recoding trust in neighbours and reading a cross-tabulation

The same survey asked about trust in neighbours on a four-point scale. The first step was to run Frequency analysis on the original responses. The presenter then used Data transformation to create a new variable by grouping original responses 1 and 2 as ‘does not trust’ and 3 and 4 as ‘trusts’. The two categories make the grouping easier to compare but lose the distinction between moderate and strong answers. Keep the original variable and a mapping to the new categories.

The cross-tabulation placed sex in the rows and recoded trust in the columns. Row percentages describe the share reporting trust within each group. A chi-square test of independence compares the observed cell counts with the counts expected if the variables were independent. Inspect counts and expected counts alongside percentages. With a complex survey, check separately whether the method accounts for weights and sampling design. NIST’s chi-square test of independence

The presenter read a Pearson chi-square p-value of 0.013, below the demonstration threshold of 0.05. Report the size of the difference in proportions alongside the p-value. A p-value concerns results at least as extreme as the observed statistic under the null hypothesis and the analysis assumptions. It measures neither the size of the difference nor the probability that the null hypothesis is true. American Statistical Association statement on p-values

Correlating annual income and outbound travel

The aggregate example paired outbound traveller counts with gross national income per capita by year. Each row represented a year, whereas each row in the earlier survey represented a respondent. Selecting the two series for correlation gives a coefficient whose sign indicates direction and whose absolute value indicates the strength of the linear association. The video reported approximately +0.86 for those two series over the period shown.

The series can share a long-term trend, and observations from adjacent years can be dependent. Check each indicator’s unit and pair values from the same year, then inspect time plots and a scatterplot for shared trends and abrupt changes. Drawing a conclusion about individual income and individual travel from the aggregate association would require suitable individual-level evidence. NIST’s guide to autocorrelation

The video asked whether the rise in income could be taken as the cause of the rise in outbound travel. A causal interpretation would require additional evidence about timing, confounding and comparison conditions, even if regression were used. Read a coefficient first as the relationship estimated by the specified model.

Importing an Excel file and checking missing codes

The Online Analysis demonstration used an Excel copy with variable names in the first row and numeric data below. Each student had one row containing satisfaction before and after a course. Unanswered cells had been filled with 99. The upload check tests whether the file can be read. The analyst still needs to check the valid range and how missing values are represented.

StepWhat the demonstration checked
Prepare the fileKeep scores on the 1–5 scale distinct from missing answers using 99 as a temporary code
Run initial descriptive statisticsNotice a maximum of 99 and a post-course mean above 5
Define missing valuesUse Data management → Define missing values to exclude 99 separately for each measure
RecheckInspect the maximum against the valid range and check the number of observations retained
CompareUse a paired t-test on students with both measurements

Entering 99 does not automatically make the program treat it as missing. Choose a code outside the valid range and check the minimum, maximum and valid count after defining it. Keep the original and upload copy separate and record which codes were applied to which variables.

Comparing the same students before and after

A paired t-test computes a difference between each student’s two scores, then compares the mean of those differences with zero. A student with one measurement missing has no pair, so the number of pairs in the test can differ from the observation count for either time point. Check the number of pairs and the distribution of the differences before interpreting the estimated mean change and confidence interval. NIST’s guide to paired observations

The output used the pre-course score minus the post-course score. A negative difference therefore indicated an increase. Reversing the subtraction reverses the sign. The demonstration calculated change in an illustrative dataset. A claim about the effect of an actual course would need to consider concurrent influences or how a comparison group changed over the same period.

Saving results and questions from the session

The demonstration distinguished exporting an output table from saving an online session to reopen later. Keep the data version, variable definitions, recoding, treatment of missing values, test and comparison direction with the table. Check the service’s retention conditions when using online storage.

In the satisfaction example, a mean beyond the top of the five-point scale was the first sign that the output needed checking. Reading from the data and variables through the valid range and observations included, then to the test result, makes it clearer what the table can support.


Share LinkedIn

Previous Note
Online Surveys in KSDC DB and Data Discovery in ICPSR