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

Standardize plot elements #36

Open
4 tasks done
sdhutchins opened this issue Dec 4, 2018 · 3 comments
Open
4 tasks done

Standardize plot elements #36

sdhutchins opened this issue Dec 4, 2018 · 3 comments

Comments

@sdhutchins
Copy link
Contributor

sdhutchins commented Dec 4, 2018

I think it'd be great if we came up with a custom format for the plots as well to improve the cohesiveness of all of the figures.

Below is currently what I've got going...

image

Mainly, I'm interested in cohesive aesthetics including:

  • location of title and legends (title on top right or center and should the title have a line under it?)
  • Labels of data
  • Font type
  • Axes lines (mainly alpha diversity vs correlation - how they look)

Things won't be perfect between the heat trees and other plots, but I think we can standardize certain elements.

I use the below code on my plots:

    theme(
      text = element_text(size = 11, family = "Arial", face = "bold"),
      axis.text.x = element_blank(), axis.ticks = element_blank(), panel.grid.major = element_blank(), panel.grid.minor = element_blank(),
      strip.background = element_rect(fill = "white"), strip.text = element_text(colour = "black"), panel.background = element_blank()
    ) +
    xlab(xlabel) + ggtitle(title) +
    annotate("segment", x = Inf, xend = -Inf, y = Inf, yend = Inf, color = "black", lwd = 1) +
    scale_y_continuous(breaks = scales::pretty_breaks(n = 25))
@grabear grabear transferred this issue from another repository Dec 20, 2018
@grabear
Copy link
Member

grabear commented Dec 20, 2018

I need to work on this for my plots. Have you done any more with this? @sdhutchins

I've also looked at https://github.com/dgkf/ggpackets as an option recently, but that package is pretty underdeveloped it seems.

@sdhutchins
Copy link
Contributor Author

sdhutchins commented Dec 20, 2018

@grabear I played around with your metacoder heat trees and it's a little harder to get them into this format which may not even be as helpful because of the metacoder package's base plot. There are ways to remove the title and re-add one, but it was just not looking as good imo.

I think your correlation plots will be easier to manipulate.

@sdhutchins
Copy link
Contributor Author

Per discussions with @xiaoumc, removing titles from plots is desired so we can just make that a default parameter (and I think it is on most of the plots).

Otherwise, colors in the ordination, metacoder, and alpha diversity plots are in sync with each other.

Legends and legend titles need tweaking for mainly alpha diversity.

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

No branches or pull requests

2 participants