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

RDA influences from microViz #89

Open
antagomir opened this issue Aug 27, 2023 · 0 comments
Open

RDA influences from microViz #89

antagomir opened this issue Aug 27, 2023 · 0 comments

Comments

@antagomir
Copy link
Member

The microViz package has nice capabilities for phyloseq.

Explore the possibilities for providing visualizations similar to this and beyond using miaViz, e.g ord_plot

library(mia)

# Get demo data
data(hitchip1006, package="miaTime")
ps <- makePhyloseqFromTreeSE(hitchip1006)
ps <- microbiome::transform(ps, "clr")

# Move to numeric
sample_data(ps)$sex <- as.numeric(as.factor(sample_data(ps)$sex))
sample_data(ps)$nationality <- as.numeric(as.factor(sample_data(ps)$nationality))

library(microViz)
p <- ordplot <- ps %>% 
  ord_calc(constraints = c("age","sex")) %>%
  microViz::ord_plot(colour = "diversity", plot_taxa = 1:8)

print(p)

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

No branches or pull requests

1 participant