Skip to main content

Streamlit component that allows you to view a SandDance visualization of a dataframe.

Project description

streamlit-sanddance

Streamlit component that allows you to view a SandDance visualization of a dataframe.

Installation instructions

pip install streamlit-sanddance

Usage instructions

import streamlit as st

from streamlit_sanddance import sanddance

#sample random DataFrame
df = pd.DataFrame(
     np.random.randn(20, 3),
     columns=['a', 'b', 'c'])

sdEvent = sanddance(df=df)

st.write(sdEvent)

The return value is a dictionary of visual interaction events such as selections.

Dev Setup

  • Ensure you have Python 3.6+.
  • Create a new Python virtual environment for the Streamlit component:
$ cd streamlit
$ python3 -m venv venv  # create venv
$ . venv/bin/activate   # activate venv
$ pip install streamlit # install streamlit
  • Initialize and run the component frontend:
$ cd streamlit/sanddance/frontend
$ npm install    # Install npm dependencies
$ npm run start  # Start the Webpack dev server
  • From a separate terminal, run the Streamlit app:
$ cd streamlit
$ . venv/bin/activate  # activate the venv you created earlier
$ pip install -e . # install streamlit-sanddance as editable package
$ streamlit run sanddance/example.py  # run the example

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

streamlit-sanddance-0.0.4.tar.gz (2.6 MB view details)

Uploaded Source

Built Distribution

streamlit_sanddance-0.0.4-py3-none-any.whl (8.0 MB view details)

Uploaded Python 3

File details

Details for the file streamlit-sanddance-0.0.4.tar.gz.

File metadata

  • Download URL: streamlit-sanddance-0.0.4.tar.gz
  • Upload date:
  • Size: 2.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.11

File hashes

Hashes for streamlit-sanddance-0.0.4.tar.gz
Algorithm Hash digest
SHA256 fc75a201aa88205b262e16ee3639aadcbf992ce5dd3db74f8de9567c7c5d7a58
MD5 3019df2450faa2672e1ed2089547c7c1
BLAKE2b-256 32ea9d6ab031dd5e33b1c8505f5911f68c96db0ebc1a7a662b68d80386335706

See more details on using hashes here.

File details

Details for the file streamlit_sanddance-0.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for streamlit_sanddance-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 96f35a9f32d002993b00b44ce80507a8d1c002fdb98e95d94daf50d30d84601d
MD5 844054d954705ac95c1a6cb0bd3c5066
BLAKE2b-256 8289a80d5af434b3f66a9b12f5f7e027faf55ea34bb5c396aa2608488063ae57

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page