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)

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.5.tar.gz (2.6 MB view details)

Uploaded Source

Built Distribution

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

Uploaded Python 3

File details

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

File metadata

  • Download URL: streamlit-sanddance-0.0.5.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.5.tar.gz
Algorithm Hash digest
SHA256 9365a4250a38a10f52f8fa93e2c008917e9fd732ed3966fe8cf07cfb7c57745c
MD5 d6740ecc5dd93fafa6f7a3fd5b633bb0
BLAKE2b-256 0cd57c9c3c42d4b1087e03f3e96da1bff35b6fab872dd8cca48ade1d1ad924cc

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for streamlit_sanddance-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 4b3aa087e58a236733f999fd1ccc8651ddcecee8a6a208766d84bf3133ef8466
MD5 e6facad9a40973258d83e7b92d21dbf3
BLAKE2b-256 d3bbf93b80b8f4e52ea2cc516a18b21d6b44eb61b635ffb7915e2dba0c1f5f81

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