-
Notifications
You must be signed in to change notification settings - Fork 116
Closed
Description
Hi! I want to create a plot with col and axis labels that need to be firstly parsed. I read here that I have to use scales::parse_format and, while it works for the fill legend, it does not seem to work for the x axis since it shows only the ticks . Am I doing something wrong? Is this a bug?
I originally posted the same issue at the github page of ggplot2 and they suggested that this could be a bug with scales since the same example works using ggplot2 internal functions.
# packages
library(ggplot2)
# data
fake_data <- data.frame(
classes = c("alpha", "beta"),
value = c(1, 2),
stringsAsFactors = FALSE
)
ggplot(fake_data) +
geom_col(aes(x = classes, y = value, fill = classes)) +
scale_fill_discrete(labels = scales::parse_format()) +
scale_x_discrete(labels = scales::parse_format())Created on 2019-04-09 by the reprex package (v0.2.1)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
