Editing Statistics and Statistical Programming (Winter 2017)/Problem Set: Week 4

From CommunityData

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 7: Line 7:
The datasets are messy and aren't set up well to help us answer the question. Luckily, we can use R to solve these problems!
The datasets are messy and aren't set up well to help us answer the question. Luckily, we can use R to solve these problems!


:'''PC1.''' Download these two datasets from data.seattle.gov, save them into your git repository: [https://data.seattle.gov/City-Business/COS-Statistics-Top5000-Pages/yuhv-gvtm COS-Statistics-Top5000-Pages] [https://data.seattle.gov/City-Business/COS-Statistics-Mobile-Sessions/2u47-byfn COS-Statistics-Mobile Sessions]. Assume, for the purposes of this assignment that the first dataset on views to the top 5000 pages is ''all'' views made to the http://www.seattle.gov website
:'''PC1.''' Download these two datasets from data.seattle.gov, save them into your git repository [https://data.seattle.gov/City-Business/COS-Statistics-Top5000-Pages/yuhv-gvtm COS-Statistics-Top5000-Pages] [https://data.seattle.gov/City-Business/COS-Statistics-Mobile-Sessions/2u47-byfn COS-Statistics-Mobile Sessions]. Assume, for the purposes of this assignment that the first dataset on views to the top 5000 pages is ''all'' views made to the http://www.seattle.gov website
:'''PC2.''' Load both datasets into R as separate data frames. Explore the data to get a sense of the structure of the data. What are the columns, rows, missing data, etc? Write code to take (and then check/look at) several random subsamples of the data.
:'''PC2.''' Load both datasets into R as separate data frames. Explore the data to get a sense of the structure of the data. What are the columns, rows, missing data, etc? Write code to take (and then check/look at) several random subsamples of the data.
:'''PC3.''' Using the top 5000 dataset, create a new data frame where one column is each month (as described in the data) and a second column is the total number of views made to all pages in the dataset over that month.
:'''PC3.''' Using the top 5000 dataset, create a new data frame where one column is each month (as described in the data) and a second column is the total number of views made to all pages in the dataset over that month.
Please note that all contributions to CommunityData are considered to be released under the Attribution-Share Alike 3.0 Unported (see CommunityData:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following CAPTCHA:

Cancel Editing help (opens in new window)