Heatmap get scrambled

You seem to have mixed rows and colums, try the transpose:

p1 = heatmap(
    x, y, z';
1 Like