sweetviz-sweetviz-with-streamlit

Sub-skill of sweetviz: Sweetviz with Streamlit (+1).

5 stars

Best use case

sweetviz-sweetviz-with-streamlit is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Sub-skill of sweetviz: Sweetviz with Streamlit (+1).

Teams using sweetviz-sweetviz-with-streamlit should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/sweetviz-with-streamlit/SKILL.md --create-dirs "https://raw.githubusercontent.com/vamseeachanta/workspace-hub/main/.agents/skills/_archive/data/analysis/sweetviz/sweetviz-with-streamlit/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/sweetviz-with-streamlit/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How sweetviz-sweetviz-with-streamlit Compares

Feature / Agentsweetviz-sweetviz-with-streamlitStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Sub-skill of sweetviz: Sweetviz with Streamlit (+1).

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Sweetviz with Streamlit (+1)

## Sweetviz with Streamlit


```python
#!/usr/bin/env python3
"""sweetviz_streamlit.py - Streamlit app for Sweetviz reports"""

import streamlit as st
import sweetviz as sv
import pandas as pd
import tempfile
import os

st.set_page_config(page_title="Sweetviz EDA", layout="wide")
st.title("Sweetviz Exploratory Data Analysis")

# File upload
uploaded_file = st.file_uploader("Upload CSV file", type=["csv"])

if uploaded_file:
    df = pd.read_csv(uploaded_file)

    st.subheader("Data Preview")
    st.dataframe(df.head(100))

    st.subheader("Dataset Info")
    col1, col2, col3 = st.columns(3)
    col1.metric("Rows", df.shape[0])
    col2.metric("Columns", df.shape[1])
    col3.metric("Missing Values", df.isnull().sum().sum())

    # Analysis options
    st.sidebar.header("Analysis Options")

    target_col = st.sidebar.selectbox(
        "Target Variable (optional)",
        ["None"] + list(df.columns)
    )

    pairwise = st.sidebar.selectbox(
        "Pairwise Analysis",
        ["auto", "on", "off"]
    )

    skip_cols = st.sidebar.multiselect(
        "Columns to Skip",
        list(df.columns)
    )

    if st.button("Generate Report"):
        with st.spinner("Generating Sweetviz report..."):
            feat_cfg = sv.FeatureConfig(skip=skip_cols) if skip_cols else None

            report = sv.analyze(
                source=df,
                target_feat=target_col if target_col != "None" else None,
                feat_cfg=feat_cfg,
                pairwise_analysis=pairwise
            )

            # Save to temp file
            with tempfile.NamedTemporaryFile(delete=False, suffix=".html") as f:
                report.show_html(f.name, open_browser=False)

                with open(f.name, "r") as html_file:
                    html_content = html_file.read()

                os.unlink(f.name)

            # Display in iframe
            st.components.v1.html(html_content, height=800, scrolling=True)
```


## Sweetviz with Jupyter Magic


```python
# In Jupyter notebook
import sweetviz as sv
import pandas as pd

# Load data
df = pd.read_csv("data.csv")

# Quick analysis (opens in new tab)
report = sv.analyze(df)
report.show_notebook()  # Opens in browser from notebook

# Inline display (for newer Jupyter versions)
report.show_notebook(
    w="100%",  # Width
    h="600px",  # Height
    scale=0.8  # Scale factor
)

# For comparison
train_df = df.sample(frac=0.8)
test_df = df.drop(train_df.index)

comparison = sv.compare(
    [train_df, "Train"],
    [test_df, "Test"]
)
comparison.show_notebook()
```