Skip to content

Add support for fractional seconds in datetime formatting #1482

@ma-galan

Description

@ma-galan

When formatting datetime axes in lets-plot, the finest resolution supported appears to be seconds. In my use case, I sometimes need to display 3 decimal places for sub-second precision on the x-axis labels and/or in hover tooltips.

Currently, the most precise format I can use is: scale_x_datetime(format="%H:%M:%S")

I think it would be very useful to support sub-second formatting, for example (or a similar syntax that exposes milliseconds/microseconds): date_format = "%Y-%m-%d %H:%M:%S.%3f"

I may be missing something, but I haven't found a way to achieve this. Any guidance or suggestions would be appreciated.

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions