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

ordr: would please like geom_GeomAxis() implemented in plotly #2329

Open
byandell opened this issue Jan 10, 2024 · 0 comments
Open

ordr: would please like geom_GeomAxis() implemented in plotly #2329

byandell opened this issue Jan 10, 2024 · 0 comments

Comments

@byandell
Copy link

I want to use plotly on a GG of a biplot using package ordr. Creating issue as advised.

# Example taken from ordr::ggbiplot
# Also partly from <https://corybrunson.github.io/ordr/>

library(ordr)

# PCA of iris data
iris_pca <- ordinate(iris, cols = 1:4, prcomp, scale = TRUE)

# row-principal predictive biplot
p <- ggbiplot(iris_pca, sec.axes = "cols", scale.factor = 2) +
  geom_rows_point(aes(color = Species, shape = Species)) +
  stat_rows_ellipse(aes(color = Species), alpha = .5, level = .99) +
  geom_cols_vector() +
  geom_cols_text_radiate(aes(label = name)) +
  expand_limits(y = c(-3.5, NA)) +
  ggtitle("PCA of Anderson's iris measurements",
          "99% confidence ellipses; variables use top & right axes")

# GGplot as seen in <https://corybrunson.github.io/ordr/>
p

# Plotly of GGplot, but "geom_GeomAxis() not implemented"
plotly::ggplotly(p)
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

1 participant