You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I really love I can generate plotly plots with rust. Working with heatmaps recently, I discovered plotly.rs is missing the xgap and ygap parameters (maybe other parameters as well). Can we have setters/setters for these parameters in plotly.rs?
Also is there some sort of workaround how I can (temporarily) set such values as long plotly.rs does not support them?
If the text parameter is simply a Vec<String> as it is basically enforced right now, the hover is simply not shown (I had to test this myself as I found the plotly docs not very readable on this one though).
I really love I can generate plotly plots with rust. Working with heatmaps recently, I discovered plotly.rs is missing the xgap and ygap parameters (maybe other parameters as well). Can we have setters/setters for these parameters in plotly.rs?
Also is there some sort of workaround how I can (temporarily) set such values as long plotly.rs does not support them?
<script src="https://cdn.plot.ly/plotly-3.3.1.min.js"></script>
If the `text` parameter is simply a `Vec` as it is basically enforced right now, the hover is simply not shown (I had to test this myself as I found the plotly docs not very readable on this one though).
Thanks for the example. This seems to be a bug. I will need to have a closer look at it. If it is a bug, I will convert your comment into a new issue.
Thanks for the reply 👍 . And yes sorry for opening two issues in one. Feel free to open the second issue in case you can verify the bug (also please ping me there so I get a notification).
Activity
atticus-sullivan commentedon Feb 9, 2026
Also it seems like for using the
textorhovertextparameters in conjunction with the heatmap, it needs to have the same dimensions as thezvalue.I made a small example demonstrating how the resulting js needs to look like (demonstrating both, the
{x,y}gapand the{hover,}textparameter:with
If the
textparameter is simply aVec<String>as it is basically enforced right now, the hover is simply not shown (I had to test this myself as I found the plotly docs not very readable on this one though).andrei-ng commentedon Feb 11, 2026
Hi,
It is straightforward to add. You just need to add the two fields to the struct definition in
plotly.rs/plotly/src/traces/heat_map.rs
Line 115 in 8162d37
Once you add the members/fields the macros will generate the setters .
Feel free to open a PR with the addition and I will merge it.
andrei-ng commentedon Feb 11, 2026
Thanks for the example. This seems to be a bug. I will need to have a closer look at it. If it is a bug, I will convert your comment into a new issue.
atticus-sullivan commentedon Feb 11, 2026
Thanks for the reply 👍 . And yes sorry for opening two issues in one. Feel free to open the second issue in case you can verify the bug (also please ping me there so I get a notification).
andrei-ng commentedon Feb 12, 2026
xgapandygapadded in #385@atticus-sullivan For the second part I opened a separate issue #386