Plotly 1 Use Plotly Express For Quick Plots

Sub-skill of plotly: 1. Use Plotly Express for Quick Plots (+4).

vamseeachanta ccebd4a 923 B Updated

File contents

1. Use Plotly Express for Quick Plots (+4)

1. Use Plotly Express for Quick Plots

# Simple and readable
fig = px.scatter(df, x='x', y='y', color='category', title='Quick Scatter')

2. Graph Objects for Complex Customization

# More control
fig = go.Figure()
fig.add_trace(go.Scatter(x=x, y=y, mode='markers'))
fig.update_layout(title='Custom Chart')

3. Optimize for Large Datasets

# Use Scattergl for >10k points
fig = go.Figure(data=go.Scattergl(x=x, y=y, mode='markers'))

4. Responsive Design

fig.update_layout(
    autosize=True,
    margin=dict(l=20, r=20, t=40, b=20)
)

5. Custom Hover Templates

fig.update_traces(
    hovertemplate='<b>%{x}</b><br>Value: %{y:.2f}<extra></extra>'
)

vamseeachanta/workspace-hub/tree/main/.agents/skills/_archive/data/visualization/plotly/1-use-plotly-express-for-quick-plots commit ccebd4a241

Frequently asked questions

npx skillmds@latest add vamseeachanta/plotly-1-use-plotly-express-for-quick-plots