Only one edge facet_grid
qplot(mpg, wt, data=mtcars) + facet_grid(cyl ~ vs, margins="vs")
When this answer was written, this behavior was not documented. It is now in the facet_grid documentation
fields are either a boolean value or a character character. Fields are additional faces that contain all data for each of the possible values of the cut variables. If
, additional faces are not included (default). If
, fields are included for all faceted variables. If specified as a character vector, these are the variable names for which you want to create fields.
(Thanks @Harry for that.)
source to share