-
-
Notifications
You must be signed in to change notification settings - Fork 67
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
If add heatmap, x-axis would be not aligned. #226
Comments
Hey @kevinyin9 Thx for submitting this issue! I'll gladly look further into this, but can you share either;
Kind regards, |
Hi @kevinyin9, Would you be so kind to provide us with a minimal example of your experience issue? Kind regards, |
ping! @kevinyin9 |
The issue you're facing is due to the way FigureWidgetResampler handles multiple traces. When you add both the scatter and heatmap traces, the resampler is trying to downsample both traces, which is causing the unexpected result. fig = make_subplots(rows=2, cols=1, shared_xaxes=True, vertical_spacing=0, row_heights=[3, 1]) Add heatmap trace without resamplerfig.add_trace( Create a new resampler figureresampler_fig = FigureWidgetResampler(fig) Add scatter trace to resampler figureresampler_fig.add_trace( |
Hello,
I’m trying to plot a stock price chart with a heatmap and a price scatter. However, when I add both the scatter and heatmap traces to the chart, the result is not what I expected.
plotly==5.15.0
plotly-resampler==0.8.3.2
dash==2.10.2.
Here’s my current code snippet:
As you can see from the images I posted below, when I add both traces, the chart doesn’t look ideal.
This chart is without FigureWidgetResampler, which is correct:
With FigureWidgetResampler, this is still correct when only price scatter exists:
With FigureWidgetResampler, this is not correct when both scatter and heatmap exists:
Also, I found that if add the scatter first then add the heatmap, the chart won't show anything.
Can anyone suggest how to solve this issue?
Thanks in advance for any help!
The text was updated successfully, but these errors were encountered: