N328 Visualizing Information Week 13: Networks & Trees Khairi - - PowerPoint PPT Presentation

n328 visualizing information
SMART_READER_LITE
LIVE PREVIEW

N328 Visualizing Information Week 13: Networks & Trees Khairi - - PowerPoint PPT Presentation

N328 Visualizing Information Week 13: Networks & Trees Khairi Reda | redak@iu.edu School of Informa5cs & Compu5ng, IUPUI tables networks friendship network Websites as networks of pages wired.com cnn.com apple.com Via Miriah Meyer


slide-1
SLIDE 1

N328 Visualizing Information

Khairi Reda | redak@iu.edu School of Informa5cs & Compu5ng, IUPUI

Week 13: Networks & Trees

slide-2
SLIDE 2

networks tables

friendship network

slide-3
SLIDE 3

cnn.com wired.com apple.com

Websites as networks of pages

Via Miriah Meyer

slide-4
SLIDE 4

Network (aka Graph)

V: Set of ver5ces (or nodes) E: Set of edges (or connec5ons) An edge e = (x, y) connects two ver5ces x and y For example:

V = {1, 2, 3, 4} E = {(1,2), (1, 4), (3, 2), (3, 4)}

1 2 3 4 1 4 3 2 1 2 3 4

Node-link diagram

slide-5
SLIDE 5

Graph terminology

Via Miriah Meyer

trees

slide-6
SLIDE 6

Graph vs. Tree

Graph

Nodes and edges No constraint on edges

Tree

Parents and children No “loops”

Hierarchical

  • rganizational

structures

Genome / phenotype similarity (tree of life)

slide-7
SLIDE 7

Node-Link Diagram

slide-8
SLIDE 8

Node-Link Diagram

http://bl.ocks.org/mbostock/4063550

slide-9
SLIDE 9

Limita5ons

  • Tree breadth tend to grow exponen5ally
  • Quickly run out of space!
  • Solu5ons
  • Scrolling or panning
  • Collapsing nodes
  • Hyperbolic layouts

Based on a slide by Miriah Meyer

Hyperbolic layout

Node-Link tree diagrams

slide-10
SLIDE 10

Icicle Plot

C A B F X Y Z D E

D E A B C F X Y Z

slide-11
SLIDE 11

Icicle Plot

slide-12
SLIDE 12

Radial Icicle Plot

http://bl.ocks.org/mbostock/raw/4348373/

slide-13
SLIDE 13

IndentaKon

  • Place all items along ver5cal

paced rows

  • Indenta5on used to show parent/

child rela5onships

  • Commonly used as a component

in user interfaces (e.g., File Explorer, Finder)

  • OUen requires significant

scrolling

Based on a slide by Miriah Meyer

slide-14
SLIDE 14

Enclosure Diagrams

  • Encode structure using spa5al enclosure
  • OUen referred to as a treemap
  • Pros
  • Provides single view of en5re tree
  • Easier to spot small/large branches
  • Cons
  • Difficult to interpret depth

Based on a slide by Miriah Meyer

C A B D E

A B C D E

slide-15
SLIDE 15

Treemap

http://homes.cs.washington.edu/~jheer//files/zoo/

slide-16
SLIDE 16

Treemap

Disk Inventory X

slide-17
SLIDE 17

Graph vs. Tree

Graph

Nodes and edges No constraint on edges

Tree

Parents and children No “loops”

slide-18
SLIDE 18

Visualizing Graphs

  • Node-link layouts
  • Force-Directed layout
  • A[ribute-based
  • Adjacency matrices
  • Aggregate Views
  • Mo5f Glyphs
  • PivotGraph
slide-19
SLIDE 19

Node-link diagrams

  • Primary concern of graph drawing is layout
  • f nodes (and ul5mately the edges)
  • Goal is to effecKvely depict the overall

graph structure

  • Connec5vity, path following
  • Clusters
  • Key readability measure: reduce the

frequency of edge crossing

1 2 3 4 1 4 3 2

slide-20
SLIDE 20

Exercise

create an aesthe5cally pleasing node-link diagram for this network

Miriah Meyer

slide-21
SLIDE 21

Exercise

Miriah Meyer

create an aesthe5cally pleasing node-link diagram for this network

slide-22
SLIDE 22

Force-directed layout

  • Physical model
  • Nodes = repulsive par5cles
  • Edges = springs

Miriah Meyer

slide-23
SLIDE 23

http://bl.ocks.org/mbostock/4062045

Force-directed layout

slide-24
SLIDE 24

Force-directed layout

  • Many varia5ons, but usually physical analogy:
  • Repulsion force: fR(d) = CR * m1*m2 / d2
  • m1, m2 are node masses
  • d is distance between nodes
  • AUracKon force: fA(d) = CA * (d – L)
  • L is the rest length of the spring
  • Total force on a node x with posi5on x’

∑ neighbors(x) : fA(||x’-y’||) * (x’-y’) + -fR(||x’-y’||) * (x’-y’)

Miriah Meyer

slide-25
SLIDE 25

Force-directed layout

  • Start from a random layout
  • Loop (top-level):
  • For every node pair, compute repulsive force
  • For every node pair, compute a[rac5ve force
  • accumulate forces per node
  • update each node posi5on in direc5on of

accumulated force

  • stop when layout is ‘good enough’

Miriah Meyer

Algorithm

slide-26
SLIDE 26

https://bl.ocks.org/mbostock/1062288

Collapsable force-directed graphs

slide-27
SLIDE 27

The internet

slide-28
SLIDE 28

Force-directed layout

  • Pros
  • Flexible, aesthe5cally pleasing layouts on many

types of graphs

  • Can add custom forces
  • Rela5vely easy to implement
  • Cons
  • Computa5onally expensive O(n3) for a non-
  • p5mized implementa5on
  • Prone to local minima

Based on a slide by Miriah Meyer

slide-29
SLIDE 29

Node-link diagram

Based on a slide by Miriah Meyer

  • Pros
  • Intui5ve visual mapping
  • Can show overall structure,

clusters, and paths

  • Cons
  • Not good for dense graphs (the

hairball problem)

slide-30
SLIDE 30

Visualizing Graphs

  • Node-link layouts
  • Force-Directed layout
  • A[ribute-based
  • Adjacency matrices
  • Aggregate Views
  • Mo5f Glyphs
  • PivotGraph
slide-31
SLIDE 31

Adjacency Matrix

Miriah Meyer

slide-32
SLIDE 32

Adjacency Matrix

https://bost.ocks.org/mike/miserables/

slide-33
SLIDE 33
  • Pros
  • Good for dense graphs
  • Visually scalable
  • Highlights clusters
  • Cons
  • Not as intui5ve, compared to a graph
  • Row/column order affects percep5on of pa[erns
  • Hard to follow paths

Adjacency Matrix

slide-34
SLIDE 34

Hybrid: node-link + matrix

NodeTrix, Henry and Fekete, 2007

slide-35
SLIDE 35

Visualizing Graphs

  • Node-link layouts
  • Force-Directed layout
  • A[ribute-based
  • Adjacency matrices
  • Aggregate Views
  • Mo5f Glyphs
  • PivotGraph
slide-36
SLIDE 36
slide-37
SLIDE 37

MoKf Glyphs

Dunne 2013

connector fan clique

slide-38
SLIDE 38

MoKf Glyphs

Dunne 2013

slide-39
SLIDE 39

MoKf Glyphs

Dunne 2013