Viewing a saved revision (read-only)
B8eWBlrtieCNgvVJ47Yi2
Created from react-d3-starter template
Star Wars Character Interaction Network
An interactive force-directed network visualization of character interactions across the Star Wars films, built with React and D3.
Dataset Overview
- Filename:
starwars_edges.csv - Rows: 1000
- Columns: 4
- Subject matter: A weighted directed edge list. Each row appears
to represent one interaction (e.g., a line of dialogue) directed from
a
sourcecharacter to atargetcharacter within a givenepisode. Thevaluecolumn appears to be a count or weight of how often that interaction occurs.
Note: The exact semantic meaning of
source,target, andvalueis inferred from the column names and structure. It is described here as tentative rather than established fact.
Column Descriptions
episode
- Represents: The Star Wars film (episode number) in which the interaction occurs.
- Munzner type: Ordinal — the values are ordered episode numbers. Computed cardinality is 8 with min 1 and max 7 (one value may be a variant/parsing artifact; treat the exact set as tentative).
- Missing values: None reported.
- Notes: Stored as a boolean type by the profiler, which likely reflects a detection quirk rather than its true meaning; treated here as an ordinal numeric episode identifier.
source
- Represents: The character initiating the interaction (the speaker or actor of the edge), by name / identifier.
- Munzner type: Nominal — unordered character identifiers.
- Missing values: None reported. Cardinality is 83.
target
- Represents: The character receiving the interaction, by name / identifier.
- Munzner type: Nominal — unordered character identifiers.
- Missing values: None reported. Cardinality is 93.
value
- Represents: The weight or count of the interaction between the source and target (e.g., number of exchanges).
- Munzner type: Quantitative — a numeric measurement.
- Missing values: None reported. Range is 1 to 77, mean ~4.126.
- Notes: Small positive integers only.
Visualization Mappings
Chart type: Force-directed network (node-link diagram) of the directed interaction graph.
- Nodes: Every distinct character appearing as a
sourceortarget. Node size encodes the character's total interaction weight (sum ofvalue) in the currently selected view. - Edges: One link per dataset row, drawn as directed curved arrows
from
sourcetotarget. - Edge width: Encodes
value(interaction weight). - Edge opacity: Encodes
valueso weak interactions recede. - Color: Edges are colored by the source character's community / rank to aid legibility; hovered and highlighted edges are emphasized.
- Interaction:
- An episode selector filters which edges are shown (or shows all episodes combined). This is the primary interaction, since the graph is otherwise a dense hairball.
- Hovering an edge highlights it and its two endpoints, dimming everything else; a tooltip shows source → target and the value.
- The layout is responsive to its container via a resize observer.
Why this design: The data is fundamentally a weighted directed graph, so a node-link diagram is the most faithful and information-rich representation. Encoding weight in edge width and node size surfaces the strongest relationships, while episode filtering tames the density of 1000 edges into comprehensible per-film views.
Files
index.html— page shell and import map (React + D3 from CDN).index.jsx— mounts<App />.App.jsx— loadsdata/starwars_edges.csv, holds episode filter state, and renders the visualization.viz.js— D3 force-directed network render entry point.useContainerDimensions.js— tracks container size for responsiveness.styles.css— page styles.README.md— this file.
Getting started
The app loads data/starwars_edges.csv at runtime. Use the episode
selector at the top to explore interactions per film, and hover edges
to inspect individual character relationships.