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

Time series of month is not continuous in the line/bar charts #32493

Open
bsenthilbalu opened this issue Mar 4, 2025 · 5 comments
Open

Time series of month is not continuous in the line/bar charts #32493

bsenthilbalu opened this issue Mar 4, 2025 · 5 comments
Labels
viz:charts:bar Related to the Bar chart viz:charts:line Related to the Line chart

Comments

@bsenthilbalu
Copy link

I tried all these, but still I don't get the month names continuously in my charts. The X-axis labels skips few months in between by 2 or 3. Any fix for this issue ?

You can put %b in x-axis to order by month name

image

Originally posted by @RenanLeiteBay in #29237

@dosubot dosubot bot added viz:charts:bar Related to the Bar chart viz:charts:line Related to the Line chart labels Mar 4, 2025
Copy link

dosubot bot commented Mar 4, 2025

Hey @bsenthilbalu! 👋 I'm here to help you with your coding conundrums!

To ensure continuous display of month names on the x-axis in Apache Superset, you might want to check the minInterval property, which determines the intervals for x-axis labels in time series charts. This property is influenced by the xAxisType and timeGrainSqla. If the xAxisType is set to AxisType.Time and timeGrainSqla is defined, the minInterval is mapped to a timestamp value. If these conditions are not met, the minInterval defaults to 0, which might cause skipping of months [1].

Additionally, ensure that your time grain settings are correctly configured to reflect monthly intervals. If the issue persists, it might be related to known issues such as time range filters not being applied correctly or time grain not being set when using Jinja in datasets [2].

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other

@bsenthilbalu
Copy link
Author

Hey @bsenthilbalu! 👋 I'm here to help you with your coding conundrums!

To ensure continuous display of month names on the x-axis in Apache Superset, you might want to check the minInterval property, which determines the intervals for x-axis labels in time series charts. This property is influenced by the xAxisType and timeGrainSqla. If the xAxisType is set to AxisType.Time and timeGrainSqla is defined, the minInterval is mapped to a timestamp value. If these conditions are not met, the minInterval defaults to 0, which might cause skipping of months [1].

Additionally, ensure that your time grain settings are correctly configured to reflect monthly intervals. If the issue persists, it might be related to known issues such as time range filters not being applied correctly or time grain not being set when using Jinja in datasets [2].

To continue talking to Dosu, mention @dosu.

Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other

Where I can see that mininterval property in the Superset chart properties ?

@hainenber
Copy link
Contributor

Can you add screenshot of line/bar charts affected by the issue? The image in description came from old post so I don't know what to debug.

Kindly anonymize any PII data if necessary.

@bsenthilbalu
Copy link
Author

Please see below

Image

@rusackas
Copy link
Member

rusackas commented Mar 4, 2025

It seems like it just skips some because the labels are too long to fit on all the X axis ticks. What would be your proposed solution?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
viz:charts:bar Related to the Bar chart viz:charts:line Related to the Line chart
Projects
None yet
Development

No branches or pull requests

3 participants