You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found when saving the theme_sg() created charts to a file, the font size came out very small. This may be a feature rather than a bug, and either way can be addressed by manually setting the font size.
However, in experimenting, I discovered that creating a chart using theme_sg() results in changes to charts created later without using theme_sg().
This, I assume, is not intended behaviour. Here is a reproducible example:
library(tidyverse)
data = tibble(x = 1:6, y = 2*x)
# with theme_light
data %>% ggplot(aes(x, y)) + geom_point() + theme_light()
ggsave("./test_light1.png", width = 15, height = 7.5, units = "cm")
# with theme_sg
data %>% ggplot(aes(x, y)) + geom_point() + sgplot::theme_sg()
ggsave("./test_sg.png", width = 15, height = 7.5, units = "cm")
# with theme_light
data %>% ggplot(aes(x, y)) + geom_point() + theme_light()
ggsave("./test_light2.png", width = 15, height = 7.5, units = "cm")
The text was updated successfully, but these errors were encountered:
This issue was caused by use of showtext. This has been removed from sgplot for now. Will investigate other methods of using Google font in theme for future release.
I found when saving the theme_sg() created charts to a file, the font size came out very small. This may be a feature rather than a bug, and either way can be addressed by manually setting the font size.
However, in experimenting, I discovered that creating a chart using theme_sg() results in changes to charts created later without using theme_sg().
This, I assume, is not intended behaviour. Here is a reproducible example:
The text was updated successfully, but these errors were encountered: