Cannot use custom colours in Hail plots


I am trying to plot the results of PCA using custom colours for my label, but I am struggling to get it to work, as I can find examples or better documentation. Please find attached a screenshot of my code.

As you can see, I create a color mapper and try to pass it to the hail plot function, which nonetheless still uses the default palette. Any help would be really appreciated. Thanks.

Best wishes,


I have found a solution, it’s working now, although I am not sure if this is the best way to do it. Thanks.