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

scale_x/y_date for string based columns is broken #146

Open
Vindaar opened this issue Apr 30, 2022 · 0 comments
Open

scale_x/y_date for string based columns is broken #146

Vindaar opened this issue Apr 30, 2022 · 0 comments

Comments

@Vindaar
Copy link
Owner

Vindaar commented Apr 30, 2022

Attempting to assign a scale date to column that stores the dates as strings is currently broken. It never calls the procedure to generate the ticks for it.

In ggplot_ticks in handleTicks we only call the tick procedure handleDateScaleTicks for continuous scales, which only applies for columns that store unix timestamps for example. For string based columns the data is considered discrete and thus we never call it.

However, fixing it requires to fix the logic that finally assigns the position, as the toCoord1D helper needs a data scale, which by default is not available for discrete scales. Maybe we can get away with computing a scale on the fly (based on the data), but possibly this breaks with the drawing logic as that would still think the scale is discrete. So likely we need to turn a date scale into a continuous scale (which causes other problems as of right now). Requires some thought.

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

No branches or pull requests

1 participant