Graph/Network Visualization
Total Page:16
File Type:pdf, Size:1020Kb
Graph/Network Visualization Data model: graph structures (relations, knowledge) and networks. Applications: – Telecommunication systems, – Internet and WWW, – Retailers’ distribution networks – knowledge representation – Trade – Collaborations – literature citations, etc. 1 What is a Graph? Vertices (nodes) Edges (links) Adjacency list 1: 2 2: 1, 3 3: 2 1 2 3 1 1 0 1 0 2 1 0 1 3 0 1 0 2 3 Drawing Adjacency matrix 2 Graph Terminology Graphs can have cycles Graph edges can be directed or undirected The degree of a vertex is the number of edges connected to it – In-degree and out-degree for directed graphs Graph edges can have values (weights) on them (nominal, ordinal or quantitative) 3 Trees are Different Subcase of general graph No cycles Typically directed edges Special designated root vertex 4 Issues in Graph visualization Graph drawing Layout and positioning Scale: large scale graphs are difficult Navigation: changing focus and scale 5 Vertex Issues Shape Color Size Location Label 6 Edge Issues Color Size Label Form – Polyline, straight line, orthogonal, grid, curved, planar, upward/downward, ... 7 Aesthetic Considerations Crossings -- minimize number of edge crossings Total Edge Length -- minimize total length Area -- minimize towards efficiency Maximum Edge Length -- minimize longest edge Uniform Edge Lengths -- minimize variances Total Bends -- minimize orthogonal towards straight-line 8 Graph drawing optimization 3D-Graph Drawing Graph visualization techniques Node-link approach – Layered graph drawing (Sugiyama) – Force-directed layout – Multi-dimensional scaling (MDS) Adjacency Matrix 11 Sugiyama (layered) method Suitable for directed graphs with natural hierarchies: All edges are oriented in a consistent direction and no pairs of edges cross Sugiyama : Building Hierarchy Assign layers according to the longest path of each vertex Dummy vertices are used to avoid path across multiple layers. Vertex permutation within a layer to reduce edge crossing. Exact optimization is NP-hard – need heuristics. Sugiyama : Building Hierarchy Force directed graph layout No natural hierarchy or order Based on principles of physics The Spring Model Using springs to represent node-node relations. Minimizing energy function to reach energy equilibrium. Initial layout is important Local minimal problem Spring Layout 17 Energy Function 18 Network of character co-occurrence in Les Misérables Multi-dimensional Scaling Dimension reduction to 2D Graph distance of two nodes are as close to 2D Euclidean distance as possible MDS is a global approach Distance between two nodes: shortest path (classical scaling). Weighted distances ( , = , ) − = w( ,)( , , ) 2 � − < MDS for graph layout Other Node-Link Methods Orthogonal layout – Suitable for UML graph Radial graph – Often used in social networks Nested graph layout – Apply graph layout hierarchically – Suitable for graphs with hierarchy Arc Diagrams Arc Diagram Les Misérables character relations Arc Diagram EU Financial Crisis: http://www.bbc.co.uk/news/business-15748696 Summary: Node-Link Pros – Intuitive – Good for global structure – Flexible, with variations Cons – Complexity >O(N2) – Not suitable for large graphs Adjacency Matrix matrix, for a graph with N nodes. (i, j) position represent the relationship of the ith node and jth node. – Adjacency Matrix Edge weight Directional edges Sorting: node order Path searching and path tracking ? 30 Node Order Path Tracking Adjacency matrix summary Avoid edge crossing, suitable for dense graphs Visually more scalable Visualization is not intuitive Hard to track a path MatLink Hybrid Layout Using adjacency matrix to represent small communities Node-link for relationships between communities NodeTrix GMap Visualizing graphs and clusters as geographic maps to represent node relations (geographic neighbors) Topological graph simplification Reducing amount of data – Reducing nodes: clustering – Reducing edges: minimal spanning tree – Edge bundling Problems: – Loss of data Clustering Edge Bundling Force Directed Edge Bundling Edges are modeled as flexible springs that are able to attract each other. Geometry Based Edge Bundling Edges clusters are found based on a geometric control mesh. Multilevel Agglomerative Edge Bundling Bottom-up merging approach, similar to hierarchical clustering Minimize amount of ink used to render a graph. Skeleton-based Edge Bundling Skeletons: medial axes of edges which are similar in terms of positions information. Iteratively attracting edges towards the skeletons. Comparison Interaction Viewing – Pan, Zoom, Rotate Interacting with graph nodes and edges – Pick, highlight, delete, move Structural interaction – Local re-order and re-layout – Focus+Context – Roll-up & Drill-down Fisheye Focus+Context; Overviews + details-on-demand Distortion to magnify areas of interest: zoom factors of 3-5 Multi-scale spaces: Zoom in/out & Pan left/right Interaction with Social Networks Need to consider the social factors and behaviors related to nodes and edges 50 Graph Visualization Tools Prefuse (Java) Pajek UCINET / NetDraw Sentinel Visualizer JUNG (Java Universal Network/Graph framework) Graphviz Gephi TouchGraph D3 http://prefuse.org/ Pajek http://prefuse.org/ Sentinel Visualizer UCINET / NetDraw Link Analysis, Data Analysis and visualization Visualization, Geospatial of networks and graphs Mapping, and Social Network Analysis (SNA) Example: trade 55 Example: email traffic 56 Example: Subway map 57 Web page connections 58 Communication Networks Hypergraphs Definition A hypergraph is a generalization of a graph, where an edge can connect any number of vertices. A hypergraph H is a pair H = (V,E) where V is a set of nodes/vertices, and E is a set of non-empty subsets of V called hyperedges/links. The Hypergraph H = (V,E) where V = (1,2,3,4,5) and E = {(1,2) (2,3,5) (1,3), (5,4) (2,3)} Applications . Data Mining . Biological Interactions . Social Networks . Circuit Diagrams Graph Representations Edge Nodes: Representative Graph.