Skip to content

Adding date_breaks to scale_*_time #4335

Closed
@llrs

Description

@llrs

I am working with a dataset where there are huge time differences.
If I use scale_*_time I cannot convert those labels to a more meaningful label such as 1 week, 2 weeks... as it can be done with scale_*_date*. Could it be possible to add the date_breaks argument to scale_*_time (or something similar)?

library("hms")
library("ggplot2")
data.frame(diff = as_hms(c(1850000, 800)), time = rep(Sys.time(), 2))
ggplot(df) +
    geom_point(aes(time, diff)) 

This would make it easier to interpret the plots.


Couldn't find any issue related to this

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions