☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

Invert color map

Community Supportbrowserwebsitebokeh
Zana
Zana

Hi,

Is it possible to inverse the color map I am using to show the higher value as dark green and blue. Snippet of code given below:

    mapper_w = LinearColorMapper(palette='Blues9', low=0, high=2)
    view_fd_w = CDSView(source=source_fd, filters=[tempInt_filter_fd, mon_filter, wn_filter, t_filter_fd, system_filter_w])
    pWS.rect(x="Date_time", y="Zone", 
                       source=source_fd, view=view_fd_w, 
                       width='w', height=1,
                       fill_color={'field': 'Fnorm', 'transform': mapper_w},
                       line_color=None)
        
    color_bar = ColorBar(color_mapper=mapper_w, major_label_text_font_size="16px",
                     ticker=BasicTicker(desired_num_ticks=2),
                     formatter=PrintfTickFormatter(format="%5.1f"),
                     label_standoff=6, border_line_color=None, location=(0, 0))
⌁   Link to post

End of archived discussion · Replies are disabled