Skip to content

karelvaculik/altair-flask-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Altair Flask Demo

This simple Python project illustrates how to use Flask to create interactive Altair plots. The motivation is that even though Altair provides a lot of interactivity features, it might be useful to create own HTML widgets, too.

image info

A change in the plot can be invoked by either Show button or any of the sliders, although it's clear that it might not be necessary in real applications. For the sake of brevity, there are no CSS.

Installation

Clone the project and then install the requirements. It is possible to do it within a virtual environment as follows:

python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt

The application was tested with Python 3.8.

How to run

Execute

FLASK_APP=altair_flask_demo/main.py flask run

and then open http://127.0.0.1:5000/ in your web browser.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published