Microsoft Research released .NetMap. A free Open Source tool for creating and viewing network graphs. Included is a set of .Net libraries to add network graphs to custom applications.
Out of the box the tool supports some great features. One feature is the support for automatic layout of the vertices like Circular, Grid and Sinusoid Horizontal to name a few.
Interactive features I like are the ability to drag the resulting nodes around on the drawing surface and clicking on a node to highlight the edges in and out of the node.
A unique feature is the VSTO component for Excel. In a spreadsheet you can specify Vertex 1 and Vertex 2. The associated task pane lets you read the spreadsheet and layout the graph with different options.
I worked up a few PowerShell scripts so I could produce graphs from different sources by:
- Importing a comma separated values file
- Importing an Excel Spreadsheet
- Running commands against the system
Here’s are the commands and their results. The csv file and excel file contain the same vertex information for the graph.
Contents of test.csv
Import-Csv test.csv | Show-NetMap
.\Import-ExcelSheet -File test -SheetName Test | Show-NetMap
.\Graph-Object (Get-Process powershell, moe*)
.\Graph-Object (Get-Service net*p*)
- Import-Excel is a wrapper a around Lee Holmes Invoke-SqlCommand found in his book Windows PowerShell Cookbook
- Graph-Object is re-worked from two sources
- My post on PowerShell + (GLEE – Graph Layout Execution Engine)
- Jeffery Snover’s great additions Graphing with Glee