I am trying to generate multiple graphs using map() function to substitute this list of copy/paste:
rvb1 <- ggplot(df)+ geom_bar(aes(x=rvb1))
rvb2 <- ggplot(df)+ geom_bar(aes(x=rvb2))
rvb3 <- ggplot(df)+ geom_bar(aes(x=rvb3))
rvb4 <- ggplot(df)+ geom_bar(aes(x=rvb4))
rvb5 <- ggplot(df)+ geom_bar(aes(x=rvb5))
rvb6 <- ggplot(df)+ geom_bar(aes(x=rvb6))
I am trying this one:
map(select(df, rvb1.17:rvb6.17), ~ggplot(.)+ geom_bar(aes(x=.)))
But I am receiving the following error: Error: 'data' must be a data frame, or other object coercible by 'fortify()', not a numeric vector
Could some good soul helpme with this task?