Question: Lab 2 Author: Date: Remember to change the author: field on this Rmd file to your own name. Loading the neccessary libraries: [ ]: library(tidyverse)

 Lab 2 Author: Date: Remember to change the author: field onthis Rmd file to your own name. Loading the neccessary libraries: [

Lab 2 Author: Date: Remember to change the author: field on this Rmd file to your own name. Loading the neccessary libraries: [ ]: library(tidyverse) 1. Changing the author field and file name. (a) Change the author: field on the Rmd document from Your Name Here to your own name. (b) Rename this file to "lab02_YourHameHere.ipynb", where YourNameHere is changed to your own name. 2. Data practice In class we imported the survey data using the read.table() function. (Note: on Homework 1 you'll be asked to use the read.csv() function instead.) This is the code we used: [ ]: survey in ----> 1 survey 2 sum(survey( [["Program"]]= "PPM")) NameError: name 'survey' is not defined (b) What % of survey respondents are from PPM? [ ]: #Edit here 3. Index practice (a) Use $ notation to pull the Operating System column from the survey data []: #Edit here (b) Do the same thing with [] notation, referring to Operating System by name [ ]: #Edit here (c) Repeat part (b), this time referring to Operating System by column number [ ]: #Edit here (d) Repeat part (b), this time using the select() function. [ ]: #Edit here (e) Use filter() and select() together to get the Program and Rexperience of every student who watched at least 10 hours of TV last week. [ ]: #Edit here 4. Optional practice Try re-running as much of the lecture code as you have time for, taking time to understand what is happening in each line of code. Tip: Instead of copying and pasting code, practice typing it yourself. This will help you to learn the syntax. [ ]: #Edit here Lab 2 Author: Date: Remember to change the author: field on this Rmd file to your own name. Loading the neccessary libraries: [ ]: library(tidyverse) 1. Changing the author field and file name. (a) Change the author: field on the Rmd document from Your Name Here to your own name. (b) Rename this file to "lab02_YourHameHere.ipynb", where YourNameHere is changed to your own name. 2. Data practice In class we imported the survey data using the read.table() function. (Note: on Homework 1 you'll be asked to use the read.csv() function instead.) This is the code we used: [ ]: survey in ----> 1 survey 2 sum(survey( [["Program"]]= "PPM")) NameError: name 'survey' is not defined (b) What % of survey respondents are from PPM? [ ]: #Edit here 3. Index practice (a) Use $ notation to pull the Operating System column from the survey data []: #Edit here (b) Do the same thing with [] notation, referring to Operating System by name [ ]: #Edit here (c) Repeat part (b), this time referring to Operating System by column number [ ]: #Edit here (d) Repeat part (b), this time using the select() function. [ ]: #Edit here (e) Use filter() and select() together to get the Program and Rexperience of every student who watched at least 10 hours of TV last week. [ ]: #Edit here 4. Optional practice Try re-running as much of the lecture code as you have time for, taking time to understand what is happening in each line of code. Tip: Instead of copying and pasting code, practice typing it yourself. This will help you to learn the syntax. [ ]: #Edit here

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!