Selected Questions as Indicated on the Questionnaire
1. How old are you? ………………………………………
2. What is your sex? Male Female
3. Have you ever smoked? Yes No
4. How were your grades in the past 12 months?
Most A’s Mostly B’s Mostly C’s
Mostly D’s Mostly F’s
5. How many times have you smoked marijuana?
0 time 1 or 2 times 3 to 9 times 10 to 19 times
20 to 39 times 40 to 99 times 100 or more times
Note: In the dataset
Female = 1 Male = 2
Yes = 1 No = 2
Mostly A’s = 1 Mostly B’s = 2 Mostly C’s = 3
Mostly D’s = 4 Mostly F’s = 5
Times smoking marijuana:
0 time = 1 1 or 2 times = 2 3 to 9 times = 3 10 to 19 times = 4
20 to 39 times = 5 40 to 99 times= 6 100 or more times = 7
Assessment 1: Individual Assignment
Weighting: 30%
Due Date: Saturday July 11 @ 11:55 PM EC/ 10:55 PM JA Time
Assignment Description and Instructions
This is an individual assignment. This assignment covers units 1-3 as well as unit 8. This
assignment is graded out of 50 and contributes 30% of your final grade.
Part 1
For this part of the assignment, you will be using the dataset, Risky Behaviour found in the
course space. You will also need to use the document, Questions for Risky Behaviour Survey.
This document has selected questions as they appeared on the questionnaire that was
administered to collect the data for this project. You are expected to use your knowledge of the
Statistical Package R in unit 8 to answer this part of the assignment. Your final assessment
submission must be in Microsoft Word or pdf format.
Note: To get full marks on part 1, you need to share all codes that you use to generate the answer
to the different questions in R.
1. Classify the variables and the levels of measurement used. Explain your choice of the
levels of measurement. (10 marks)
2. Using R, calculate the mean age and standard deviation of respondents. Report this in a
complete sentence. (4 marks)
3. Using R, calculate the mean age and standard deviation by gender. Is there a difference in
the age distribution by gender? Explain. (10 marks)
4. Using R, generate a graph to represent the sample by frequency of marijuana
consumption. What can you say about the marijuana consumption of this sample of
teenagers? (6 marks)
5. Using appropriate command (s) in R, populate the following table with the number of
persons who ever smoked by gender. (4 points)
Gender Ever Smoked Total
Yes No
Male
Female
Total
6. Use the table that you populated in question 5 above to calculate the following:
a. The probability of randomly selecting a teenager from this sample that is female and
smoke marijuana. (2 marks)
b. The probability of randomly selecting a teenager from this sample that smokes.
(2 marks)
c. Are the events “Smoked” and “Male” independent? Why or why not? (2 marks)
Part 2
This part of the assignment does not require the use of any statistical package such as R but
instead requires you to practice your computational skills.
7. The table below shows the distance travelled by a random sample of 120 residents to the
only health clinic in a small rural community.
Distance
(kilometers)
Number of
Residents
Relative
Frequency
0-9 10
10-19 19
20-29 43
30-39 25
40-49 8
50-59 9
60-69 6
a. Complete the table above by writing in values for the relative frequency. (2 marks)
b. What proportion of residents has to travel 30 km or more to the health clinic?
(1 mark)
c. Calculate the mean distance in km traveled by residents to the health clinic.
(3 marks)
d. Calculate the standard deviation for the distance traveled by residence to the health
clinic. (4 marks)
Science is the pursuit and application of knowledge and understanding of the natural and social…
Clearly stating the definition, the values, the meaning of such values and the type of…
All answered must be typed using Times New Roman (size 12, double-spaced) font. No pictures…
All answered must be typed using Times New Roman (size 12, double-spaced) font. No pictures…
https://www.npr.org/sections/ed/2018/04/25/605092520/high-paying-trade-jobs-sit-empty-while-high-school-grads-line-up-for-university Click on the link above. Read the entire link and answer the questions below…
All answered must be typed using Times New Roman (size 12, double-spaced) font. No pictures…