Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

facet_matrix() does not respect scale_y_continuous(position = "right") #163

Open
seasmith opened this issue Aug 14, 2019 · 1 comment
Open

Comments

@seasmith
Copy link

Swapping the axis and strip text does not seem possible. Could a position.y.axis argument be added to achieve this?

library(ggplot2)
library(ggforce)

ggplot(iris, aes(.panel_x, .panel_y)) +
  geom_point() +
  geom_autodensity() +
  scale_y_continuous(position = "right") +
  facet_matrix(vars(Sepal.Length:Petal.Length),
               layer.diag = 2, switch = "y") 

ish-axis-position

@thomasp85
Copy link
Owner

deleted prior post because I misread the issue

yes, it is true that any settings applied with scale_x_* or scale_y_* are ignored as per the note in the docs:

Due to the special nature of this faceting it slightly breaks the ggplot2 API, in that any positional scale settings are ignored. This is because each row and column in the grid will potentially have very different scale types and it is not currently possible to have multiple different scale specifications in the same plot object.

I hope to figure out a fix for this in the future

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants