a) Using flip() command b) Using coord_flip() command c) Using swap() command d) Using coord_swap() command e) None of the above, it is not possible in R using ggplot2 libraries Response: The correct answer is option b. You can swap x and y axes using the function coord_flip(). This way x-axis and y-axis can be defined vertical/horizontal and vice versa depending on the columns we choose from the existing dataset. The below code snippet can be used to represent the plot represented in figure A above. Here weight is shown in y-axis and group information is shown in the x-axis. library(ggplot2) x <- ggplot(PlantGrowth, aes(x=group, y=weight)) + geom_boxplot() x + labs(title = "Plot - figure a") Now we can use the following to convert the plot to figure b. x + coord_flip()