Bar chart error when height is zero

I am trying to make a bar chart using the bar chart library. I know I've done this successfully in the past, but right now I'm getting an error that when the height of a bar is supposed to be zero, there is actually a big bar that is drawn and covers the labels on the x axis.

I've tried looking into the source code for the bar chart block but no glaring errors popped out. I just imported the library today.

Here is the link to my project:
https://snap.berkeley.edu/snap/snap.html#present:Username=gseiche&ProjectName=U5L3-ProcessingData

Does anyone know how to make the bar chart work successfully?

What's problem you are encountering?

What have you tried that didn't work?

Post a project example, link, or screenshot:

I don't know what the actual problem is but can confirm that your project works fine in V9.2.17

There is an issue with zero values under investigation by Jens at the the moment so it might be related to that

*was

The issue was just fixed (today) in v10.4.1.

Does this project work for you now? (as it's still not working for me in V10.4.2)

I've fixed the block that had the issue:
U5L3-ProcessingData script pic
What seems to be going on is that this script:


will leave a dot in the latest version, much like

did in the past. I just added an edge case for zero in the fixed block.

Well worked out :slight_smile:

I deleted the library and tried to re-import it, but I still got the same error. Can you point me specifically to where you edited the block? Thanks!

Ah, script pictures are "smart": you can drag them into Snap! and the block(s) will be loaded. I can post a project if this isn't working for you (sometimes the forum compresses the image and it stops working).

Please post a project as I too, cannot import your script pic

https://snap.berkeley.edu/snap/snap.html#present:Username=mark4sisb&ProjectName=Fixed%20Bar%20Chart

This worked! Thank you so much!

Thanks for debugging this!

One could make a case for drawing a one-pixel-tall bar if the value is zero, especially if the bars are drawn in a different color from the axes. What do y'all think?