doubt in assignment
for the assignment...airquality data set is html file.
how to read it and store in a variable.
R More-Functions-in-dplyr-Package 07-08 min 10-20 sec
Answers:
Please note that airquality is a built-in dataset in RStudio. You can simply use this by calling its name as and when needed. For instance, I am trying to plot the two variables of this dataset as given below:
(airquality$Solar.R, airquality$Ozone)
its still not working
02-05-20, 1:51 a.m.
archana.naware@gmail.com
Please see whether you are able to view the data by executing View(airquality).
02-05-20, 1:59 a.m.
sudhakarst
No. HTML file is displayed
02-05-20, 11:38 a.m.
archana.naware@gmail.com
I am assuming that you have installed R and RStudio on your machine. Then, you are trying to load the data in RStudio.
02-05-20, 12:26 p.m.
sudhakarst
library(dplyr)
# use Built In data set airquality. Using select function,
#select the variables Ozone, Wind, Temp in this dataset.
View(airquality)
airqualitySOW <- select(airquality$Ozone, airquality$Wind, airquality$Temp)
View(airqualitySOW)
View(mtcars)
mtcars <- read.csv("mtcars.csv")
mtcarsR <- rename( mtcars, MilePerGallon = "mpg" ,
Cylinder = "cyl")
View(mtcarsR)
for the bold text in above I get output as
> airqualitySOW <- select(airquality$Ozone, airquality$Wind, airquality$Temp)
Error in UseMethod("select_") :
no applicable method for 'select_' applied to an object of class "c('integer', 'numeric')"
> View(airqualitySOW)
>
airqualitySOW <- select(airquality,c(Ozone, Wind, Temp))
02-05-20, 2:47 p.m.
archana.naware@gmail.com
tried this and got output.