Question: Use and show R code (a map function) to find the median for each quantitative variable column of the iris data table. This is what
Use and show R code (a map function) to find the median for each quantitative variable column of the iris data table.
This is what I have so far, but I don't know if Im headed in the right direction:
library(tidyverse)
view(iris) sl <- iris$Sepal.Length sw <- iris$Sepal.Width pl <- iris$Petal.Length pw <- iris$Petal.Width
iris2 <- pmap_dbl(list(sl, sw, pl, pw), median) view(iris2)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
