Question: 1. Open RStudio and create a new script with an appropriate name 2. Add a comment to the top of the script with your name

1. Open RStudio and create a new script with an appropriate name

2. Add a comment to the top of the script with your name

3. Create a Word document to report your results in

4. Explore the airquality dataset in R using ?, help, and head. Briefly describe the dataset in your Word document. Which attributes have missing values?

5. Try to computer the mean of airquality$Ozone. Why doesn't it work? Is there an argument you can pass to the function to make it work? (hint: use ?mean)

6. The na.omit function can be used to remove rows with missing data from a dataset. Use na.omit to create a version of airquality without missing data, and call it airquality.complete

7. Calculate the mean of the Ozone attribute in airquality.complete. Is it different from the result from part 5? Why?

8. Create another version of the airquality data set which replaces missing values with the attribute mean for those values, called airquality.meanfixed. (hint: the functions which and is.na can be combined into which(is.na(attribute)), and will give all the indices for an attribute that are empty)

9. Using the your meanfixed dataset, calculate the correlation between Solar.R and Temp. Are they positively or negatively correlated? Does the correlation appear to be strong? Is the correlation significant?1. Open RStudio and create a new script with an appropriate name

Overview In this assignment you will use some of the techniques you have learned about in Chapter 3 in conjunction with the airquality dataset in R. Action Items 1. Open RStudio and create a new script with an appropriate name 2. Add a comment to the top of the script with your name 3. Create a Word document to report your results in 4. Explore the airquality dataset in R using ?, help, and head. Briefly describe the dataset in your Word document. Which attributes have missing values? 5. Try to computer the mean of airquality $ Ozone. Why doesn't it work? Is there an argument you can pass to the function to make it work? (hint: use ?mean) 7. Calculate the mean of the Ozone attribute in airquality.complete. Is it different from the result from part 5? Why? which(is.na(attribute)), and will give all the indices for an attribute that are empty) Submission Instructions Example: Submit your completed assignment (R script and Word Document) here by the 11:59pm on Thursday, February 16 th. Grading Criteria This assignment is worth 20 points. 2 Points for each task 3-7 (8 points total) 7 points for task 8 5 points for task 9

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!