I really like the style of Plotly Python’s sliders, as in this example:
import pandas as pd
import numpy as np
import plotly.offline as py
py.init_notebook_mode(connected=False)
data = [ dict(
visible = False,
name = '𝜈 = '+str(step),
x = np.arange(0,10,0.01),
y = np.sin(step*np.arange(0,10,0.01)) ) for step in np.arange(0,5,0.1) ]
steps = []
for i in range(len(data)):
step = dict(
method = 'restyle',
args = ['visible', [False] * len(data) ],
)
step['args'][1][i] = True # Toggle i'th trace to "visible"
steps.append(step)
sliders = [ dict(
active = 10,
currentvalue = {"prefix": "Frequency: "},
pad = {"t": 50},
steps = steps
) ]
layout = dict( sliders = sliders )
fig = dict( data = data, layout = layout )
py.iplot( fig, filename = 'Sine wave slider' )
with this output:
So, how do I style the dcc.Slider to give an output like this?