Announcing Dash Bio 1.0.0 🎉 : a one-stop-shop for bioinformatics and drug development visualizations.

Pop index out of range in for animation facets with imshow

Hey Plotly-People!

I am working on a combined matrix animation with facet plots in using imshow and the example of Imshow | Python | Plotly.

Unfortunately I get the error: pop index out of range.

My Code is:

fig = px.imshow(xav, animation_frame=‘time’, facet_col = ‘variable’, binary_string=True)

The Input Data is a 4-D XArray with the dimensions (variable, y, x, time) and the shape of (2, 472, 464, 5).

It works perfectly fine to plot an Animation with a 3D-Subset (x,y,time), but when I try to make a facet plot for a single timestep, with a 3D-array (x,y,variable), the pop index error shows up again. My goal is to plot two different variables next to each other in order to see the difference.

I am quite clueless where the error comes from and I hope someone of you can help me!


So I selfsolved the problem with converting the input data to numpy.arrays. I leave this post here for the next one with this issue.