diff --git a/doc/how_to/callbacks/examples/streaming_bokeh.md b/doc/how_to/callbacks/examples/streaming_bokeh.md index fc0385c985..2c56251731 100644 --- a/doc/how_to/callbacks/examples/streaming_bokeh.md +++ b/doc/how_to/callbacks/examples/streaming_bokeh.md @@ -1,6 +1,6 @@ # Streaming Bokeh -```{pyodide} +```python import numpy as np import panel as pn @@ -12,7 +12,7 @@ pn.extension(template='fast') This example demonstrates how to use `add_periodic_callback` to stream data to a Bokeh plot. -```{pyodide} +```python p = figure(sizing_mode='stretch_width', title='Bokeh streaming example') xs = np.arange(1000) diff --git a/doc/how_to/callbacks/examples/streaming_indicator.md b/doc/how_to/callbacks/examples/streaming_indicator.md index 8b4a8dd84c..0c28a50bc3 100644 --- a/doc/how_to/callbacks/examples/streaming_indicator.md +++ b/doc/how_to/callbacks/examples/streaming_indicator.md @@ -1,6 +1,6 @@ # Streaming Indicator -```{pyodide} +```python import numpy as np import panel as pn @@ -9,7 +9,7 @@ pn.extension(template='fast') This example demonstrates how to use `add_periodic_callback` to stream data to the `Trend` indicator. -```{pyodide} +```python layout = pn.layout.FlexBox(*( pn.indicators.Trend( data={'x': list(range(10)), 'y': np.random.randn(10).cumsum()}, diff --git a/doc/how_to/callbacks/examples/streaming_perspective.md b/doc/how_to/callbacks/examples/streaming_perspective.md index 5c11800e57..93ddde7cee 100644 --- a/doc/how_to/callbacks/examples/streaming_perspective.md +++ b/doc/how_to/callbacks/examples/streaming_perspective.md @@ -1,6 +1,6 @@ # Streaming Perspective -```{pyodide} +```python import numpy as np import pandas as pd import panel as pn @@ -10,7 +10,7 @@ pn.extension('perspective', template='fast', sizing_mode='stretch_width') This example demonstrates how to use `add_periodic_callback` to stream data to a `Perspective` pane. -```{pyodide} +```python df = pd.DataFrame(np.random.randn(10, 4), columns=list('ABCD')).cumsum() rollover = pn.widgets.IntInput(name='Rollover', value=15) diff --git a/doc/how_to/callbacks/examples/streaming_tabulator.md b/doc/how_to/callbacks/examples/streaming_tabulator.md index acbcb5c407..14a5a7522d 100644 --- a/doc/how_to/callbacks/examples/streaming_tabulator.md +++ b/doc/how_to/callbacks/examples/streaming_tabulator.md @@ -1,6 +1,6 @@ # Streaming Tabulator -```{pyodide} +```python import numpy as np import pandas as pd import panel as pn @@ -10,7 +10,7 @@ pn.extension('tabulator', template='fast', sizing_mode="stretch_width") This example demonstrates how to use `add_periodic_callback` to stream data to a `Tabulator` pane. -```{pyodide} +```python df = pd.DataFrame(np.random.randn(10, 4), columns=list('ABCD')).cumsum() rollover = pn.widgets.IntInput(name='Rollover', value=15)