Assignment
Title
Question
Not able to find the mean of sepal length and sepal width.
Following output is obtained .
iris %>% group_by(Species) %>% summarise(mean(Sepal.Length) %>% summarise(mean(Sepal.Width))
+
R Pipe-Operator 11-12 min 20-30 sec
Answers:
You should use the commands, as given below:
iris %>% group_by(Species) %>% summarise(mean(Sepal.Length))
iris %>% group_by(Species) %>% summarise(mean(Sepal.Width))
Please note that these are two separate commands. You will require to run these two queries, one by one, to know the desired mean value.
When I run library(ggplot2) and library(dplyr) then only it is identifying %>%.How do we come to know which library is required for which command ?
Login to add comment