Reactive dashboard with Shiny in Python

tutorial by TalkPython
math
Author
Published

September 9, 2024

Modified

September 9, 2024

Set up & play with a template

Build from the scratch

Simple ui

Show the code
from shiny.express import ui

ui.h1("My Dashboard")

ui.p("This is sometext")

Let’s render something

Show the code
from shiny.express import ui, render
from pathlib import Path

import pandas as pd

file_path = Path(__file__).parent / "penguins.csv"
df = pd.read_csv(file_path)

ui.h1("My Dashboard")

ui.p("This is sometext")

@render.data_frame
def data():    
    return df

Let’s create a filter, input