具有两个变量的构面网格,但仅显示一个构面标签

时间:2019-10-23 18:51:19

标签: r ggplot2

我正在使用ggplot2来显示一些图形。 我在此示例中使用的是facet_grid

   data(mtcars)
 p<-ggplot(data=mtcars,aes(y=hp,x=wt))+
     geom_point()+facet_grid(cyl+vs ~ .)

在我得到的绘图中,我只想对变量vs而不是变量cyl进行facet_labels播放。我该怎么办?

0 个答案:

没有答案