Presentations
v0.3.0HTML slide decks built from components: titles, bullets, images, links and live Plotly charts. Compose slides manually with the Slide context manager or let Presentation.auto() build the whole deck from a DataFrame.
Automatic Deck
auto_slides.py
python
import viewx as vx
df = vx.load_dataset("penguins.csv")
pres = vx.Presentation.auto(df, title="Penguins Analysis")
pres.save("slides.html")The automatic builder profiles the DataFrame and generates a cover, KPI slides, chart slides per ranked column and a closing table slide — all with the chosen theme.
Manual Composition
Slides are built with a context manager; each component takes a width in grid units:
manual_slides.py
python
import viewx as vx
pres = vx.Presentation(title="Q4 Results", theme="dark_enterprise")
with pres.slide() as slide:
slide.add(vx.Title("Q4 Revenue"))
slide.add(vx.Subtitle("Latin America region"))
slide.add(vx.BulletList(["+18% YoY", "Record quarter", "Churn down to 3%"]))
with pres.slide() as slide:
slide.add(vx.PlotlyChart(vx.plot(df, kind="line", x="month", y="revenue")))
with pres.slide() as slide:
slide.add(vx.Title("Thank you"))
slide.add(vx.Hyperlink("Full dashboard", "https://example.com"))
pres.save("slides.html")Components
| Component | Purpose |
|---|---|
| Title / Subtitle | Headings for the slide |
| Text / BulletList | Paragraphs and bullet points |
| Image / Video | Embedded media from file or URL |
| Hyperlink / Link / Button | Navigation and call-to-action elements |
| IconStat / RotatingIcon / MovingFigure | Animated accent components |
| PlotlyChart / BarPlot / LinePlot / ScatterPlot / AreaPlot / PiePlot / DonutPlot | Charts embedded as live Plotly figures |
API Reference
Presentation
Presentation(title='Presentation', theme='corporate_blue')
Presentation.auto
Presentation.auto(df, title=None, theme=None) -> Presentation
Presentation
slide
with pres.slide() as slide
Slide.add
slide.add(component, width=12)
save / show
save(path) / show()