Question

In: Statistics and Probability

Movies 3a and 3b: 1. Using either R studio and/or SPSS calculate the mean and standard...

Movies 3a and 3b: 1. Using either R studio and/or SPSS calculate the mean and standard deviation for the question 4 data (first tab in your excel spreadsheet). Be sure to cut and paste your output from SPSS and/or your R code into this document. (1 point) The standard deviation was: The mean was:

Age 5 3 5 3 2 3 1 2 4 2 4 2 6 5 5 4 3 5 3 1 4 2 3 5 6 4 4 2 9 8 9 7 7 2 6 4 9 7

Solutions

Expert Solution

Dear student, I have performed it in R studio, I hope it helps. In the case of any doubt, please comment and I would love to clarify it.

sd() is the function in R to calculate the standard deviation whereas mean() is the function to calculate the mean of the dataset.

Code used -

#assigning the dataset to the variable age
age = c(5,3,5,3,2,3,1,2,4,2,4,2,6,5,5,4,3,5,3,1,4,2,3,5,6,4,4,2,9,8,9,7,7,2,6,4,9,7)

#calculating the mean and assigning it to variable mean_age
mean_age <- mean(age)

#calculating standard deviation by using the function sd
sd(age)

Output

> mean_age
[1] 4.368421
> sd(age)
[1] 2.222989


Related Solutions

Movies 6b and 6c Part A - Using either R studio and/or SPSS, calculate a t-test...
Movies 6b and 6c Part A - Using either R studio and/or SPSS, calculate a t-test for independent means for the question 10 data in your dataset. Be sure to cut and paste your output into this document. When using R this should include your code. Be sure to report the t-test in the correct format AND a complete write up in a paragraph form following the example in the movie. The research hypothesis asked if there are differences between...
Using built in R functions to calculate mean and standard deviation. Simulate the X vector with...
Using built in R functions to calculate mean and standard deviation. Simulate the X vector with a length of 50 from a normal distribution with mean 2 and variance 1. Using a for() loop, create 100 different confidence intervals and also create a variable that keeps a count of how many of these confidence intervals contain the true mean 2. Hint: Use If/else statement to keep track of whether the confidence interval contains the true mean or not within the...
For the reaction 3A(g)+3B(g)⇌C(g) Kc = 30.2 at a temperature of 377 ∘C . Calculate the...
For the reaction 3A(g)+3B(g)⇌C(g) Kc = 30.2 at a temperature of 377 ∘C . Calculate the value of Kp. Express your answer numerically. Kp = Part B For the reaction X(g)+3Y(g)⇌3Z(g) Kp = 2.06×10−2 at a temperature of 357 ∘C . Calculate the value of Kc. Express your answer numerically. Kc =
A. For the reaction 3A(g)+3B(g)⇌C(g) Kc = 36.0 at a temperature of 191 ∘C . Calculate...
A. For the reaction 3A(g)+3B(g)⇌C(g) Kc = 36.0 at a temperature of 191 ∘C . Calculate the value of Kp . Kp = __________ B. For the reaction X(g)+3Y(g)⇌2Z(g) Kp = 1.47×10−2 at a temperature of 19 ∘C . Calculate the value of Kc . Express your answer numerically. Kc= _______
USING R STUDIO- Write the r commands for the following. 1. Non-Linear Models 1.1 Load the...
USING R STUDIO- Write the r commands for the following. 1. Non-Linear Models 1.1 Load the {ISLR} and {GGally} libraries. Load and attach the College{ISLR} data set. [For you only]: Open the College data set and its help file and familiarize yourself with the data set and its fields. 1.2 Inspect the data with the ggpairs(){GGally} function, but do not run the ggpairs plots on all variables because it will take a very long time. Only include these variables in...
I want this to be solved using R studio or R software, please. Here is the...
I want this to be solved using R studio or R software, please. Here is the example: The data in stat4_prob5 present the performance of a chemical process as a function of sever controllable process variables. (a) Fit a multiple regression modelrelating CO2product (y) to total solvent (x1) and hydrogen consumption (x2) and report the fitted regression line. (b) Find a point estimatefor the variance term σ2. (c) Construct the ANOVA tableand test for the significance of the regression using...
Need To Do this in R Studio...Here are the Instruction steps: 1. Using the 1:n construct,...
Need To Do this in R Studio...Here are the Instruction steps: 1. Using the 1:n construct, create the sequence 4,8,12, ..., 48. 2. Similarly, create the sequence 0,5,10,15, ..., 100. 3. Using a for() loop and the print() function, print the values 2,3,4,..., 7. 4. Using a for() loop and the print() function, print the values 8,11,14, ..., 26. 5. Create a vector with a length of 10. Then, using a for() loop, assign the values 3,6,9, ..., 30. to...
(In this problem first find the probability by using SPSS and then calculate the number of...
(In this problem first find the probability by using SPSS and then calculate the number of trees manually by using the probabilities.) A certain variety of pine tree has a mean trunk diameter of μ=150 cm, and a standard deviation of σ=30 cm which is normally distributed. A certain section of a forest has 500 of these trees. Find Approximately 1. how many of these trees have a diameter smaller than 120 2. how many of these trees have a...
Using R studio 1. Read the iris data set into a data frame. 2. Print the...
Using R studio 1. Read the iris data set into a data frame. 2. Print the first few lines of the iris dataset. 3. Output all the entries with Sepal Length > 5. 4. Plot a box plot of Petal Length with a color of your choice. 5. Plot a histogram of Sepal Width. 6. Plot a scatter plot showing the relationship between Petal Length and Petal Width. 7. Find the mean of Sepal Length by species. Hint: You could...
Using Net Benefit to Evaluate Risk Response Alternatives Cooper Movie Studio Corp. makes movies and is...
Using Net Benefit to Evaluate Risk Response Alternatives Cooper Movie Studio Corp. makes movies and is interested in lowering its operating costs for the following year, while maintaining the high quality and appeal of its movies. Cooper’s management is concerned about the additional costs the company would have to incur if new industry regulation is passed by Congress. The chart at the top of the next page contains a description of this top risk, an inherent risk assessment, three risk...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT