Finding hp >100 and cyl=3
Following error is appearing on writing the command 

mtcarshpcyl <- filter(mtcarshpcyl,cyl=3 & hp>100)
Error in filter(mtcarshpcyl, cyl = 3 & hp > 100) : 
  unused argument (cyl = 3 & hp > 100)
> View(mtcarshpcyl)
Error in View : object 'mtcarshpcyl' not found


R Data-Manipulation-using-dplyr-Package 12-13 min 0-10 sec 11-12-20, 11:09 a.m. Joohi

Answers:

You should modify your command, as given below:

mtcarshpcyl <- filter(mtcars, cyl == 4 & hp > 100)

Please note that the first argument inside the filter function is the name of the data frame, which is mtcars. The second argument is the values by which we want to filter the data frame.



11-12-20, 7:34 p.m. sudhakarst


thanks
14-12-20, 3:48 p.m. Joohi


Click here to reply/comment online