
Interactive Dashboards and Data Apps with Plotly and Dash
By :

The simplest way to create these is by using a dictionary: {0: '$1.9', 1: '$3.2', 2: '$5.5'}
. They keys will be used as the value
attribute, and the values of the dictionary are what the user will see for each poverty level. This will suffice for our case, and we can use it as such.
We optionally have the chance to customize the style of our labels, which can take any CSS attribute as a dictionary. If you look at Figure 6.21, you can see that the marks (numbers) of the two sliders have a very light color, and they might give the impression that they belong to the same slider. We can improve this by setting their colors to a dark color. We can also set a bold font for the indicator slider. This will help distinguish them from the years, and it will also emphasize their uniqueness. Years are easy to immediately grasp, but users are most likely not familiar with the levels of poverty tracked in the dataset....