Makie - Clipped heatmap


Is there a way to get a clipped heatmap in Makie? MWE would be:

# Packages
using GLMakie

# Ranges
a = -3:0.033:3
b = -3:0.033:3

# Function
f(x,y) = (x*y)/(1-abs(x+y))

# Plot
_fig = Figure()
_hmap = heatmap(_fig[1,1], a, b, f)

Obviously, it should not be totally green, but the singularities get all the color, and the rest none.
Is there a way I can limit (in a heatmap, not contourf) the values for the color gradient?

Thanks in advance

Oh the heatmap page really needs more examples. Have a look at the upper right plot in the example at the bottom on this page Colorbar

Whoa, yeah, that was obscure.

What does colorrange do exactly?

Also, is there a way to control exactly from which value to which value are gradient colors used, and when are clipped colors used?

Are these two questions the same? :laughing:

Either the range of colormap lookup is determined automatically as the extrema of the data, or you set it manually with colorrange. If there are values exceeding the range, you can either leave them saturated at the extreme color value, or give them a separate color with highclip and lowclip

Yay, nice, thanks a lot!