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

Uploaded Source

Built Distribution

streamlit_sanddance-0.0.3-py3-none-any.whl (5.3 MB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: streamlit-sanddance-0.0.3.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.3.tar.gz
Algorithm Hash digest
SHA256 243b64385b74fdeea0e58c7f1afeaf4044c335c55a32f82b2a97af569d695c87
MD5 cb8f3c82016272faffd3295a6c4b3f16
BLAKE2b-256 6fad0440383da1aa86728a4cb4aad54c183d1ea530ff7ac0535d1e35a497436c

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for streamlit_sanddance-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 83798d285839f855880272f314cb0566b3ace8455bf0a84eaf4ee79cf2c2097e
MD5 e5ffcf4aa84aa2373d92f4a0713dcb9b
BLAKE2b-256 094e383a0f9495e7d4c6dc0f7bfba251a1a8981e40fa996f86216b41ac1c37d7

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