Due: March 30 by 11:59pm

Submit: To submit this assignment, create a zip file of all the files in your R project folder for this assignment. Name the zip file hw9-netID.zip, replacing netID with your netID (e.g., hw9-jph.zip). Use this link to submit your file.

Weight: This assignment is worth 5% of your final grade.

Purpose: The purposes of this assignment are:

Assessment: Each question indicates the % of the assignment grade, summing to 100%. The credit for each question will be assigned as follows:

The reflection portion is always worth 10% and graded for completion.

Rules:

1) Staying organized [SOLO, 5%]

Download and use this template for your assignment. Inside the “hw9” folder, open and edit the R script called “hw9.R” and fill out your name, GW Net ID, and the names of anyone you worked with on this assignment.

Using good style

For this assignment, you must use good style to receive full credit. Follow the best practices described in this style guide.

2) Inspect package data [SOLO, 15%]

Write R code to install the dslabs package from CRAN, then write code to load the package. Write some code to preview and inspect the movielens data frame that gets loaded when you load the package using some of the techniques we saw in class. For each of the following questions, write code to find your answer and leave a detailed response in a comment:

3) Answer questions about the data [COLLABORATIVE, 25%]

For each of the following questions, write code to find your answer and leave a detailed response in a comment:

4) Loading and inspecting external data [SOLO, 20%]

Write R code to read in the prisoners2019.csv file located in the data folder. Store the object as df. Write some code to preview and inspect the df data frame using some of the techniques we saw in class. For each of the following questions, write code to find your answer and leave a detailed response in a comment:

5) Answer questions about the data [COLLABORATIVE, 25%]

For each of the following questions, write code to find your answer and leave a detailed response in a comment:

6) Read and reflect [SOLO, 10%]

Read and reflect on next week’s readings on data wrangling. Afterwards, in a comment (#) in your R file, write a short reflection on what you’ve learned and any questions or points of confusion you have about what we’ve covered thus far. This can just few a few sentences related to this assignment, next week’s readings, things going on in the world that remind you something from class, etc. If there’s anything that jumped out at you, write it down.


EMSE 4571: Intro to Programming for Analytics (Spring 2022)
Thursdays | 12:45 - 3:15 PM EST | Tompkins 208 | Dr. John Paul Helveston | jph@gwu.edu
LICENSE: CC-BY-SA