I have got a column in an attribute table with values from about -10 to +200. I would like to create a bar chart whose x-axis only has two classes: The first class will have values from -10 up to -1 (only integer values exist), the second class contains all positive values from 0 to 200. How does this work? I don't find a way to edit the amount of classes.
At first, I wanted to create a pie chart, but I noticed quickly that pie charts cannot contain negative values....
Instead of using a field as category, you can use an Arcade expression:
return IIf($feature.YourField < 0, "x < 0", "x >= 0")
Using this, you can easily create Bar and Pie Charts:
You can also use the expression to calculate a new field in your table and use that field as category field for bar/pie charts. This has the added advantage that you can also use it in other chart types. FOr example, here is a box plot of the integer values by category: