Highlighting cells by value with a colorscale like a heatmap

I am trying to implement the highlighting cells by value with heatmap. The heatmap legend appears but no cells are colored. There are also no tick values for the legend. Does someone know why?

html.Div(legend, style={'textAlign': 'center'}),
dash_table.DataTable(
                                id='heatmap-table',
                                columns = [
                                    {"name": i, "id": i, "selectable": True} for i in df.columns
                                ],
                                data = df.to_dict('records'),
                                sort_action='native',
                                style_table={
                                    'minWidth': '100%',
                                    'height': '500px',
                                    'overflowY': 'auto',
                                },
                                style_cell={
                                    'textAlign': 'center',
                                    'minWidth': '80px', 'width': '100px', 'maxWidth': '120px',
                                },
                                style_header={
                                    'fontWeight': 'bold',
                                },
                                style_data_conditional=styles

                            ),

the problem was that one value was “inf” so the coloring function could not set up the ranges correctly.

hi @nilsleh , are you able to share final code and output? I’m working through a similar approach and am interested to see your example