You are on page 1of 6

JTMS-03 Applied Statistics with R

Spring Semester 2023

Example sample questions 1


May 11, 2023

In your role of Integration Officer for the City State of Bremen, you research the attitudes of Bremen's
citizens toward diversity in the German society. For this purpose, you use the subsample for Bremen (n =
79) from the 2019 Vielfaltsbarometer study of Robert Bosch Stiftung. The study examined the extent to
which citizens accept social diversity along age, disability, gender roles, ethnicity, religion and socio-
economic status. Each of these diversity dimensions was assessed with three to four items. Respondents’
answers were summarized into an index for each dimension that can take scores from 0 to 100. The data
are representative of the population aged 16 and older.

Data
Source Robert-Bosch-Stiftung (2019)
Variables
age Respondent’s age in years
age Respondent’s age (in years)
female Respondent’s biological sex (0= male, 1= female)
div_eth Acceptance of ethnic diversity (0= complete rejection to 100= complete acceptance)
div_rel Acceptance of religious diversity (0= complete rejection to 100= complete acceptance)

Tasks
Q1. Check whether the data are indeed representative with respect to age. Test the hypothesis that the
average age in the Bremer sample does not differ from the average age of the population of Bremen.
According to the local Statistical Office, the average age of the population of Bremen was 43.6 years in the
year of data collection (2018). Based on the available output, mark the statements below as ‘true’ (T) or
‘false’ (F).

library(psych)
describe(age)
## vars n mean sd median min max range skew kurtosis se
## X1 1 79 59.63 16.41 61 17 90 73 -0.55 0.08 1.85

t.test(age, mu= 43.6)


##
## data: age
## t = 8.6823, df = 78, p-value = 4.465e-13
## alternative hypothesis: true mean is not equal to 43.6
## 95 percent confidence interval:
## 55.95294 63.30347
## sample estimates:
## mean of x
## 59.62821

a) 79 respondents from Bremen took part in the survey.


b) The appropriate method for testing the hypothesis is the one-sample t-test.
c) The tested hypothesis is effectively the null hypothesis.
d) The average age of the respondents from Bremen is about 59.6 years.

1
e) The population of Bremen is on average about 16 years older than the participants in the survey.
f) The observed difference between the sample mean and the average age of the overall population
of Bremen is not significant at the 1 % level.
g) The appropriate style to report the evidence from the test is: t (78) = 8.68, p ≤ 0.01.
h) It is not meaningful to compare the mean age in the sample against the average age of the overall
population, since the sample is representative only for citizens above the age of 16.

Q2. Examine to what extent men and women differ in their attitudes toward ethnic diversity. Test the
hypothesis that men are on average less tolerant of ethnic diversity than women are. Based on the available
output, mark the statements below as ‘true’ (T) or ‘false’ (F).

describeBy(div_eth, group = female, mat= T, digits= 2)


## item group1 vars n mean sd median min max range
## X11 1 Man 1 35 72.39 24.61 77.80 0.00 100 100.00
## X12 2 Woman 1 44 78.75 18.44 88.68 22.23 100 77.77

t.test(div_eth ~ female, var.equal= TRUE)


##
## Two Sample t-test
##
## data: div_eth by female
## t = -1.3146, df = 77, p-value = 0.1925
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -16.011512 3.277288
## sample estimates:
## mean in group Man mean in group Woman
## 72.38667 78.75378

t.test(div_eth ~ female, var.equal= FALSE)


##
## Welch Two Sample t-test
##
## data: div_eth by female
## t = -1.2726, df = 61.455, p-value = 0.2079
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -16.369920 3.635696
## sample estimates:
## mean in group Man mean in group Woman
## 72.38667 78.75378

a) 35 men and 44 women from Bremen took part in the study.


b) The appropriate method for testing the hypothesis is the independent-samples t-test.
c) The tested hypothesis is one-tailed.
d) The average level of accepting ethnic diversity for women is about 6.36 points higher than that of
men.
e) The observed mean difference is statistically significant at the 5 % level.
f) The test assuming unequal variances renders a similar result to the ‘classical’ t-test .
g) The appropriate style to report the evidence from the test is: F = -1.3146, p = 0.1925.
h) The data provide empirical support for the hypothesis.

2
Q3. Check whether respondents accept ethnic and religious diversity to the same extent. Based on the
available output, mark the statements below as ‘true’ (T) or ‘false’ (F).

describe(div_eth)
## vars n mean sd median min max range skew kurtosis se
## X1 1 79 75.93 21.48 77.8 0 100 100 -1.25 1.63 2.42
describe(div_rel)
## vars n mean sd median min max range skew kurtosis se
## X1 1 79 50.48 22.82 55.57 0 100 100 -0.03 -0.44 2.57

t.test(div_eth, div_rel, paired=TRUE)


##
## Paired t-test
##
## data: div_eth and div_rel
## t = 10.118, df = 78, p-value = 7.503e-16
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## 20.44842 30.46718
## sample estimates:
## mean of the differences
## 25.4578

a) The descriptive evidence suggests that citizens of Bremen are on average more accepting of ethnic
diversity than of religious diversity.
b) The appropriate method to test the hypothesis is the independent-samples t-test.
c) The tested hypothesis is effectively the null hypothesis.
d) The observed difference in the means of the two dimensions is about 25.46 units.
e) The observed mean difference is significant at the 1 % level.
f) The appropriate style to report the evidence is: t (78) = 10.12, p < 0.01.
g) It can be concluded that the acceptance of religious diversity by citizens of Bremen is significantly
weaker than that of ethnic diversity.
h) The hypothesis cannot be empirically supported with the data.

3
Question 1.
Let's go through each statement one by one:

a) 79 respondents from Bremen took part in the survey.


True (T). The statement confirms that there were 79 respondents from Bremen in the
survey.

b) The appropriate method for testing the hypothesis is the one-sample t-test.
True (T). The appropriate method for testing the hypothesis about the average age is the
one-sample t-test since we are comparing the mean age of the sample to a known
population mean.

c) The tested hypothesis is effectively the null hypothesis.


True (T). In this case, the tested hypothesis is that the average age in the Bremer sample
does not differ from the average age of the population of Bremen. This hypothesis is
effectively the null hypothesis.

d) The average age of the respondents from Bremen is about 59.6 years.
True (T). The mean age of the respondents from Bremen is 59.63 years, as indicated by
the output from the describe(age) function.

e) The population of Bremen is on average about 16 years older than the participants in
the survey.
False (F). The average age of the population of Bremen in the year of data collection
(2018) was given as 43.6 years, which is younger than the average age of the
respondents in the survey (59.63 years).

f) The observed difference between the sample mean and the average age of the overall
population of Bremen is not significant at the 1% level.
False (F). The output from the t-test provides a p-value of 4.465e-13, which is much
smaller than 0.01 (1% significance level). Therefore, the observed difference between the
sample mean and the average age of the overall population of Bremen is significant at
the 1% level.

g) The appropriate style to report the evidence from the test is: t (78) = 8.68, p ≤ 0.01.
True (T). The appropriate style to report the evidence from the test is indeed: t (78) =
8.68, p ≤ 0.01. The t-value, degrees of freedom, and p-value are provided in the output
from the t-test.

h) It is not meaningful to compare the mean age in the sample against the average age
of the overall population since the sample is representative only for citizens above the
age of 16.
False (F). While it is true that the sample is representative only for citizens above the age
of 16, it is still meaningful to compare the mean age in the sample against the average
age of the overall population of Bremen. The sample can provide insights into the age
distribution and potential differences between the sample and the population.
Let's evaluate each statement:
Question 2

a) 35 men and 44 women from Bremen took part in the study.


True (T). The statement confirms the number of men (35) and women (44) who
participated in the study.

b) The appropriate method for testing the hypothesis is the independent-samples t-test.
True (T). The appropriate method for testing the hypothesis about the difference in
attitudes toward ethnic diversity between men and women is the independent-samples t-
test.

c) The tested hypothesis is one-tailed.


False (F). The tested hypothesis is not specified as one-tailed in the given information.
The provided output does not indicate a one-tailed test either.

d) The average level of accepting ethnic diversity for women is about 6.36 points higher
than that of men.
False (F). The output from describeBy() shows that the mean for women (78.75) is higher
than that for men (72.39), but the difference is not specified as 6.36 points. Therefore, we
cannot confirm this statement.

e) The observed mean difference is statistically significant at the 5% level.


False (F). The p-value from the t-test (assuming equal variances) is 0.1925, which is
greater than 0.05 (5% significance level). Therefore, we fail to reject the null hypothesis,
and the observed mean difference is not statistically significant at the 5% level.

f) The test assuming unequal variances renders a similar result to the 'classical' t-test.
True (T). The statement is supported by the information provided. The output mentions a
Welch Two Sample t-test, which assumes unequal variances. Since the p-value is also
given, we can conclude that the result is similar to the 'classical' t-test assuming equal
variances.

g) The appropriate style to report the evidence from the test is: F = -1.3146, p = 0.1925.
False (F). The appropriate style to report the evidence from the test should use "t" instead
of "F" because it is a t-test, not an F-test. The correct style would be: t = -1.3146, p =
0.1925.

h) The data provide empirical support for the hypothesis.


False (F). Since the p-value is greater than 0.05 (5% significance level), we fail to reject
the null hypothesis. Therefore, the data do not provide empirical support for the
hypothesis that men are on average less tolerant of ethnic diversity than women are.
Question 3.
Let's evaluate each statement:

a) The descriptive evidence suggests that citizens of Bremen are on average more
accepting of ethnic diversity than of religious diversity.
True (T). As mentioned in the output of the describe() function, the mean score for
accepting ethnic diversity (75.93) is higher than the mean score for accepting religious
diversity (50.48).

b) The appropriate method to test the hypothesis is the independent-samples t-test.


False (F). The appropriate method to test the hypothesis would be a paired t-test since
the data provided are paired measurements of the same individuals, assessing their
attitudes toward ethnic and religious diversity.

c) The tested hypothesis is effectively the null hypothesis.


False (F). The tested hypothesis is not explicitly mentioned in the given information.
However, in a paired t-test, the null hypothesis would typically be that there is no
difference in the means of the two dimensions (ethnic and religious diversity).

d) The observed difference in the means of the two dimensions is about 25.46 units.
False (F). The output of the t-test does not provide the observed difference in the
means of the two dimensions. Therefore, we cannot confirm this statement.

e) The observed mean difference is significant at the 1% level.


True (T). The output of the t-test shows a very small p-value (7.503e-16), which is
much smaller than 0.01 (1% significance level). Therefore, we can conclude that the
observed mean difference is statistically significant at the 1% level.

f) The appropriate style to report the evidence is: t (78) = 10.12, p < 0.01.
False (F). The appropriate style to report the evidence should include the paired nature
of the test. The correct style would be: t(78) = 10.118, p < 0.01.

g) It can be concluded that the acceptance of religious diversity by citizens of Bremen


is significantly weaker than that of ethnic diversity.
True (T). Since the p-value is very small, we can reject the null hypothesis and
conclude that there is a significant difference in the mean scores of accepting ethnic
and religious diversity. Therefore, it can be concluded that the acceptance of religious
diversity by citizens of Bremen is significantly weaker than that of ethnic diversity.

h) The hypothesis cannot be empirically supported with the data.


False (F). The data provide empirical support for the hypothesis since the t-test
indicates a significant difference between the means of accepting ethnic and religious
diversity. Therefore, the hypothesis can be empirically supported with the data.

You might also like