Is there a way to get rid of the aliasing in the contourf!
lines in the following example?
using CairoMakie
function testcontourf()
xs = LinRange(0, 10, 100)
ys = LinRange(0, 10, 100)
zs = [cos(x) * sin(y) for x in xs, y in ys]
f = Figure()
ax = Axis(f[1, 1])
c = contourf!(ax, xs, ys, zs, levels = 50)
Colorbar(f[1, 2], c)
display(f)
end
testcontourf()
In actuality, I’d prefer to get the plot to look the way it does if I double the contourf!
call, and eliminated the lines that show up.
function testcontourf_double()
xs = LinRange(0, 10, 100)
ys = LinRange(0, 10, 100)
zs = [cos(x) * sin(y) for x in xs, y in ys]
f = Figure()
ax = Axis(f[1, 1])
c = contourf!(ax, xs, ys, zs, levels = 50)
c = contourf!(ax, xs, ys, zs, levels = 50)
Colorbar(f[1, 2], c)
display(f)
end
testcontourf_double()
Which results in this image without the lines.