Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Venn Diagram

Signature

sp.venn(title, labels, values, *, variant="basic", **kwargs) -> Chart

Aliases: sp.venn, sp.venn_diagram, sp.euler, sp.set_diagram, sp.overlap

Description

Venn diagrams show set relationships using overlapping circles. Supply one value per set for circle sizes. The "euler" variant scales circle radii proportionally to the first N values.

Variants

Data

labels (list[str]) — Set names. values (list[float]) — Set sizes (first N entries used for Euler radii). width / height (int) — Chart dimensions.

Parameters

Themes

Returns

Chart — object with .html property and .show() method.

Semi-transparent overlapping circles

Variant "basic"Aliases basic / default / classic
Preview

Proportional circle areas (Euler diagram)

Variant "euler"Aliases euler / proportional / area
Preview

Fully opaque circles

Variant "filled"Aliases filled / solid / opaque
Preview

Forces every circle into its stroke-only outline form regardless of the configured fill opacity, for a clean contour-only read of the set overlaps.

Variant "minimal"Aliases minimal / outline / thin
Preview

Masks each circle down to the region that belongs to it alone and renders that region at full color, while shared/overlapping areas fade into the background — makes it obvious what's unique to each set versus what's shared.

Variant "exclusive"Aliases exclusive / unique / distinct
Preview