

{"id":2046,"date":"2013-02-08T08:02:55","date_gmt":"2013-02-08T13:02:55","guid":{"rendered":"http:\/\/rud.is\/b\/?p=2046"},"modified":"2018-03-10T07:53:38","modified_gmt":"2018-03-10T12:53:38","slug":"extended-simple-example-asn-graph-visualization-example-r-to-d3","status":"publish","type":"post","link":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/","title":{"rendered":"Extended (Simple) ASN Graph Visualization Example [R to D3]"},"content":{"rendered":"<p>The small <code>igraph<\/code> visualization in the <a href=\"https:\/\/rud.is\/b\/2013\/02\/07\/retrieve-ip-asn-bgp-peer-info-with-r\/\">previous post<\/a> shows the basics of what you can do with the <code>BulkOrigin<\/code> &amp; <code>BulkPeer<\/code> functions, and I thought a larger example with some basic <a href=\"https:\/\/d3js.org\/\">D3<\/a> tossed in might be even more useful.<\/p>\n<p>Assuming you have the previous functions in your environment, the following builds a larger graph structure (the IPs came from an overnight sample of <code><a href=\"http:\/\/en.wikipedia.org\/wiki\/Pcap\">pcap<\/a><\/code> captured communication between my MacBook Pro &amp; cloud services) and plots a similar circular graph:<\/p>\n<pre lang=\"rsplus\">\nlibrary(igraph)\n\nips = c(\"100.43.81.11\",\"100.43.81.7\",\"107.20.39.216\",\"108.166.87.63\",\"109.152.4.217\",\"109.73.79.58\",\"119.235.237.17\",\"128.12.248.13\",\"128.221.197.57\",\"128.221.197.60\",\"128.221.224.57\",\"129.241.249.6\",\"134.226.56.7\",\"137.157.8.253\",\"137.69.117.58\",\"142.56.86.35\",\"146.255.96.169\",\"150.203.4.24\",\"152.62.109.57\",\"152.62.109.62\",\"160.83.30.185\",\"160.83.30.202\",\"160.83.72.205\",\"161.69.220.1\",\"168.159.192.57\",\"168.244.164.254\",\"173.165.182.190\",\"173.57.120.151\",\"175.41.236.5\",\"176.34.78.244\",\"178.85.44.139\",\"184.172.0.214\",\"184.72.187.192\",\"193.164.138.35\",\"194.203.96.184\",\"198.22.122.158\",\"199.181.136.59\",\"204.191.88.251\",\"204.4.182.15\",\"205.185.121.149\",\"206.112.95.181\",\"206.47.249.246\",\"207.189.121.46\",\"207.54.134.4\",\"209.221.90.250\",\"212.36.53.166\",\"216.119.144.209\",\"216.43.0.10\",\"23.20.117.241\",\"23.20.204.157\",\"23.20.9.81\",\"23.22.63.190\",\"24.207.64.10\",\"24.64.233.203\",\"37.59.16.223\",\"49.212.154.200\",\"50.16.130.169\",\"50.16.179.34\",\"50.16.29.33\",\"50.17.13.221\",\"50.17.43.219\",\"50.18.234.67\",\"63.71.9.108\",\"64.102.249.7\",\"64.31.190.1\",\"65.210.5.50\",\"65.52.1.12\",\"65.60.80.199\",\"66.152.247.114\",\"66.193.16.162\",\"66.249.71.143\",\"66.249.71.47\",\"66.249.72.76\",\"66.41.34.181\",\"69.164.221.186\",\"69.171.229.245\",\"69.28.149.29\",\"70.164.152.31\",\"71.127.49.50\",\"71.41.139.254\",\"71.87.20.2\",\"74.112.131.127\",\"74.114.47.11\",\"74.121.22.10\",\"74.125.178.81\",\"74.125.178.82\",\"74.125.178.88\",\"74.125.178.94\",\"74.176.163.56\",\"76.118.2.138\",\"76.126.174.105\",\"76.14.60.62\",\"76.168.198.238\",\"76.22.130.45\",\"77.79.6.37\",\"81.137.59.193\",\"82.132.239.186\",\"82.132.239.97\",\"8.28.16.254\",\"83.111.54.154\",\"83.251.15.145\",\"84.61.15.10\",\"85.90.76.149\",\"88.211.53.36\",\"89.204.182.67\",\"93.186.30.114\",\"96.27.136.169\",\"97.107.138.192\",\"98.158.20.231\",\"98.158.20.237\")\norigin = BulkOrigin(ips)\npeers = BulkPeer(ips)\n\ng = graph.empty() + vertices(ips,size=10,color=\"red\",group=1)\ng = g + vertices(unique(c(peers$Peer.AS, origin$AS)),size=10,color=\"lightblue\",group=2)\nV(g)$label = c(ips, unique(c(peers$Peer.AS, origin$AS)))\nip.edges = lapply(ips,function(x) {\n  c(x,origin[origin$IP==x,]$AS)\n})\nbgp.edges = lapply(unique(origin$BGP.Prefix),function(x) {\n  startAS = unique(origin[origin$BGP.Prefix==x,]$AS)\n  pAS = peers[peers$BGP.Prefix==x,]$Peer.AS\n  lapply(pAS,function(y) {\n    c(startAS,y)\n  })\n})\ng = g + edges(unlist(ip.edges))\ng = g + edges(unlist(bgp.edges))\nE(g)$weight = 1\ng = simplify(g, edge.attr.comb=list(weight=\"sum\"))\nE(g)$arrow.size = 0\ng$layout = layout.circle\nplot(g)\n<\/pre>\n<p>I&#8217;ll let you run that to see how horrid a large, style-\/layout-unmodified circular layout graph looks.<\/p>\n<p>Thanks to a <a href=\"https:\/\/stackoverflow.com\/questions\/13159575\/using-a-graphml-file-for-d3-js-force-directed-layout\/13211552\">snippet<\/a> on StackOverflow, it&#8217;s really easy to get this into D3:<\/p>\n<pre lang=\"rsplus\">library(RJSONIO) \ntemp<-cbind(V(g)$name,V(g)$group)\ncolnames(temp)<-c(\"name\",\"group\")\njs1<-toJSON(temp)\nwrite.graph(g,\"\/tmp\/edgelist.csv\",format=\"edgelist\")\nedges<-read.csv(\"\/tmp\/edgelist.csv\",sep=\" \",header=F)\ncolnames(edges)<-c(\"source\",\"target\")\nedges<-as.matrix(edges)\njs2<-toJSON(edges)\nasn<-paste('{\"nodes\":',js1,',\"links\":',js2,'}',sep=\"\")\nwrite(asn,file=\"\/tmp\/asn.json\")<\/pre>\n<p>We can take the resulting <code>asn.json<\/code> file and use it as a drop-in replacement for one of the <a href=\"https:\/\/bl.ocks.org\/mbostock\/4062045\">example D3 force-directed layout building blocks<\/a> and produce this:<\/p>\n<p><center><div id=\"attachment_2048\" style=\"width: 310px\" class=\"wp-caption aligncenter\"><a target=\"_blank\" href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-2048\" data-attachment-id=\"2048\" data-permalink=\"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/vc_60\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?fit=647%2C499&amp;ssl=1\" data-orig-size=\"647,499\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;}\" data-image-title=\"vc_60\" data-image-description=\"\" data-image-caption=\"&lt;p&gt;Click for larger&lt;\/p&gt;\n\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?fit=510%2C393&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?resize=300%2C231&#038;ssl=1\" alt=\"Click for larger\" width=\"300\" height=\"231\" class=\"size-medium wp-image-2048\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?resize=300%2C231&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?resize=150%2C115&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?resize=530%2C408&amp;ssl=1 530w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?resize=535%2C412&amp;ssl=1 535w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?w=647&amp;ssl=1 647w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><p id=\"caption-attachment-2048\" class=\"wp-caption-text\">Click for larger<\/p><\/div><\/center><\/p>\n<p>Rather than view a static image, you can <a href=\"https:\/\/rud.is\/d3\/asn\/asn.html\" target=\"_blank\">view the resulting D3 visualization<\/a> (warning: it's fairly big).<\/p>\n<p>Both the conversion snippet and the D3 code can be easily tweaked to add more detail and be a tad more interactive\/informative, but I'm hoping this larger example provides further inspiration for folks looking to do computer network analysis &amp; visualization with R and may also help some others build more linkages between R &amp; D3.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The small igraph visualization in the previous post shows the basics of what you can do with the BulkOrigin &amp; BulkPeer functions, and I thought a larger example with some basic D3 tossed in might be even more useful. Assuming you have the previous functions in your environment, the following builds a larger graph structure [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":true,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":3,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[666,678,673,674,3,91],"tags":[684],"class_list":["post-2046","post","type-post","status-publish","format-standard","hentry","category-d3","category-data-visualization","category-datavis-2","category-dataviz","category-information-security","category-r","tag-netintel"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Extended (Simple) ASN Graph Visualization Example [R to D3] - rud.is<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Extended (Simple) ASN Graph Visualization Example [R to D3] - rud.is\" \/>\n<meta property=\"og:description\" content=\"The small igraph visualization in the previous post shows the basics of what you can do with the BulkOrigin &amp; BulkPeer functions, and I thought a larger example with some basic D3 tossed in might be even more useful. Assuming you have the previous functions in your environment, the following builds a larger graph structure [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/\" \/>\n<meta property=\"og:site_name\" content=\"rud.is\" \/>\n<meta property=\"article:published_time\" content=\"2013-02-08T13:02:55+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2018-03-10T12:53:38+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60-300x231.png\" \/>\n<meta name=\"author\" content=\"hrbrmstr\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"hrbrmstr\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/\"},\"author\":{\"name\":\"hrbrmstr\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\"},\"headline\":\"Extended (Simple) ASN Graph Visualization Example [R to D3]\",\"datePublished\":\"2013-02-08T13:02:55+00:00\",\"dateModified\":\"2018-03-10T12:53:38+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/\"},\"wordCount\":229,\"commentCount\":1,\"publisher\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\"},\"image\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2013\\\/02\\\/vc_60-300x231.png\",\"keywords\":[\"netintel\"],\"articleSection\":[\"d3\",\"Data Visualization\",\"DataVis\",\"DataViz\",\"Information Security\",\"R\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/\",\"url\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/\",\"name\":\"Extended (Simple) ASN Graph Visualization Example [R to D3] - rud.is\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2013\\\/02\\\/vc_60-300x231.png\",\"datePublished\":\"2013-02-08T13:02:55+00:00\",\"dateModified\":\"2018-03-10T12:53:38+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#primaryimage\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2013\\\/02\\\/vc_60.png?fit=647%2C499&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2013\\\/02\\\/vc_60.png?fit=647%2C499&ssl=1\",\"width\":647,\"height\":499,\"caption\":\"Click for larger\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2013\\\/02\\\/08\\\/extended-simple-example-asn-graph-visualization-example-r-to-d3\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/rud.is\\\/b\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Extended (Simple) ASN Graph Visualization Example [R to D3]\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#website\",\"url\":\"https:\\\/\\\/rud.is\\\/b\\\/\",\"name\":\"rud.is\",\"description\":\"&quot;In God we trust. All others must bring data&quot;\",\"publisher\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/rud.is\\\/b\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\",\"name\":\"hrbrmstr\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\",\"width\":460,\"height\":460,\"caption\":\"hrbrmstr\"},\"logo\":{\"@id\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\"},\"description\":\"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7\",\"sameAs\":[\"http:\\\/\\\/rud.is\"],\"url\":\"https:\\\/\\\/rud.is\\\/b\\\/author\\\/hrbrmstr\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Extended (Simple) ASN Graph Visualization Example [R to D3] - rud.is","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/","og_locale":"en_US","og_type":"article","og_title":"Extended (Simple) ASN Graph Visualization Example [R to D3] - rud.is","og_description":"The small igraph visualization in the previous post shows the basics of what you can do with the BulkOrigin &amp; BulkPeer functions, and I thought a larger example with some basic D3 tossed in might be even more useful. Assuming you have the previous functions in your environment, the following builds a larger graph structure [&hellip;]","og_url":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/","og_site_name":"rud.is","article_published_time":"2013-02-08T13:02:55+00:00","article_modified_time":"2018-03-10T12:53:38+00:00","og_image":[{"url":"https:\/\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60-300x231.png","type":"","width":"","height":""}],"author":"hrbrmstr","twitter_card":"summary_large_image","twitter_misc":{"Written by":"hrbrmstr","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#article","isPartOf":{"@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/"},"author":{"name":"hrbrmstr","@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"headline":"Extended (Simple) ASN Graph Visualization Example [R to D3]","datePublished":"2013-02-08T13:02:55+00:00","dateModified":"2018-03-10T12:53:38+00:00","mainEntityOfPage":{"@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/"},"wordCount":229,"commentCount":1,"publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"image":{"@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#primaryimage"},"thumbnailUrl":"https:\/\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60-300x231.png","keywords":["netintel"],"articleSection":["d3","Data Visualization","DataVis","DataViz","Information Security","R"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/","url":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/","name":"Extended (Simple) ASN Graph Visualization Example [R to D3] - rud.is","isPartOf":{"@id":"https:\/\/rud.is\/b\/#website"},"primaryImageOfPage":{"@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#primaryimage"},"image":{"@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#primaryimage"},"thumbnailUrl":"https:\/\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60-300x231.png","datePublished":"2013-02-08T13:02:55+00:00","dateModified":"2018-03-10T12:53:38+00:00","breadcrumb":{"@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#primaryimage","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?fit=647%2C499&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2013\/02\/vc_60.png?fit=647%2C499&ssl=1","width":647,"height":499,"caption":"Click for larger"},{"@type":"BreadcrumbList","@id":"https:\/\/rud.is\/b\/2013\/02\/08\/extended-simple-example-asn-graph-visualization-example-r-to-d3\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/rud.is\/b\/"},{"@type":"ListItem","position":2,"name":"Extended (Simple) ASN Graph Visualization Example [R to D3]"}]},{"@type":"WebSite","@id":"https:\/\/rud.is\/b\/#website","url":"https:\/\/rud.is\/b\/","name":"rud.is","description":"&quot;In God we trust. All others must bring data&quot;","publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/rud.is\/b\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886","name":"hrbrmstr","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","width":460,"height":460,"caption":"hrbrmstr"},"logo":{"@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1"},"description":"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7","sameAs":["http:\/\/rud.is"],"url":"https:\/\/rud.is\/b\/author\/hrbrmstr\/"}]}},"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p23idr-x0","jetpack_likes_enabled":true,"jetpack-related-posts":[{"id":2590,"url":"https:\/\/rud.is\/b\/2013\/08\/21\/zeroaccess-bots-desperately-seeking-freedom-visualization\/","url_meta":{"origin":2046,"position":0},"title":"ZeroAccess Bots Desperately Seeking Freedom (Visualization)","author":"hrbrmstr","date":"2013-08-21","format":false,"excerpt":"I've been doing a bit of graphing (with real, non-honeypot network data) as part of the research for the book I'm writing with @jayjacobs and thought one of the images was worth sharing (especially since it may not make it into the book :-). Click image for larger view This\u2026","rel":"","context":"In &quot;Data Visualization&quot;","block_context":{"text":"Data Visualization","link":"https:\/\/rud.is\/b\/category\/data-visualization\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":2123,"url":"https:\/\/rud.is\/b\/2013\/02\/20\/rnetintel-cross-check-apt-1s-ip-list-with-alienvault-reputation-db-some-graphsanalysis\/","url_meta":{"origin":2046,"position":1},"title":"R\/netintel : Cross-check APT-1&#8217;s IP list with AlienVault Reputation DB (+ some graphs\/analysis)","author":"hrbrmstr","date":"2013-02-20","format":false,"excerpt":"Here's a quick example of couple additional ways to use the netintel R package I've been tinkering with. This could easily be done on the command line with other tools, but if you're already doing scripting\/analysis with R, this provides a quick way to tell if a list of IPs\u2026","rel":"","context":"In &quot;Charts &amp; Graphs&quot;","block_context":{"text":"Charts &amp; Graphs","link":"https:\/\/rud.is\/b\/category\/charts-graphs\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":3968,"url":"https:\/\/rud.is\/b\/2016\/02\/20\/working-with-the-clinton-state-dept-email-dumps-in-r-part-1-graphs\/","url_meta":{"origin":2046,"position":2},"title":"Working with the Clinton State Dept Email Dumps in R (Part 1: Graphs)","author":"hrbrmstr","date":"2016-02-20","format":false,"excerpt":"I put this together after experimenting with `ggplot2` and `ggnetwork` earlier this week. The changes I made added `svgPanZoom` into the mix. Consequently, it has a widget in it, so it was just easier to embed the full R markdown HTML into an `iframe` than to try to extract the\u2026","rel":"","context":"In &quot;R&quot;","block_context":{"text":"R","link":"https:\/\/rud.is\/b\/category\/r\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":4209,"url":"https:\/\/rud.is\/b\/2016\/03\/27\/nuclear-animations-in-d3\/","url_meta":{"origin":2046,"position":3},"title":"Nuclear Animations in D3","author":"hrbrmstr","date":"2016-03-27","format":false,"excerpt":"As I said, I'm kinda obsessed with the \"nuclear\" data set. So much so that I made a D3 version that's similar to the R version I made the other day. I tried not to code much today (too much Easter fun going on), so I left off the size\u2026","rel":"","context":"In &quot;cartography&quot;","block_context":{"text":"cartography","link":"https:\/\/rud.is\/b\/category\/cartography\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/03\/ogimg.png?fit=1200%2C946&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/03\/ogimg.png?fit=1200%2C946&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/03\/ogimg.png?fit=1200%2C946&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/03\/ogimg.png?fit=1200%2C946&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/03\/ogimg.png?fit=1200%2C946&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":4396,"url":"https:\/\/rud.is\/b\/2016\/05\/14\/global-temperature-change-in-r-d3-without-the-vertigo\/","url_meta":{"origin":2046,"position":4},"title":"Global Temperature Change in R &#038; D3 (without the vertigo)","author":"hrbrmstr","date":"2016-05-14","format":false,"excerpt":"This made the rounds on social media last week: Spiraling global temperatures from 1850-2016 (full animation) https:\/\/t.co\/YETC5HkmTr pic.twitter.com\/Ypci717AHq\u2014 Ed Hawkins (@ed_hawkins) May 9, 2016 One of the original versions was static and was not nearly as popular, but\u2014as you can see\u2014this one went viral. Despite the public's infatuation with circles\u2026","rel":"","context":"In &quot;Charts &amp; Graphs&quot;","block_context":{"text":"Charts &amp; Graphs","link":"https:\/\/rud.is\/b\/category\/charts-graphs\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/hadcrut.png?fit=1200%2C600&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/hadcrut.png?fit=1200%2C600&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/hadcrut.png?fit=1200%2C600&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/hadcrut.png?fit=1200%2C600&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/hadcrut.png?fit=1200%2C600&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":3278,"url":"https:\/\/rud.is\/b\/2015\/02\/15\/introducing-the-streamgraph-htmlwidget-r-pacakge\/","url_meta":{"origin":2046,"position":5},"title":"Introducing the streamgraph htmlwidget R Package","author":"hrbrmstr","date":"2015-02-15","format":false,"excerpt":"We were looking for a different type of visualization for a project at work this past week and my thoughts immediately gravitated towards [streamgraphs](http:\/\/www.leebyron.com\/else\/streamgraph\/). The TLDR on streamgraphs is they they are generalized versions of stacked area graphs with free baselines across the x axis. They are somewhat [controversial](http:\/\/www.visualisingdata.com\/index.php\/2010\/08\/making-sense-of-streamgraphs\/) but\u2026","rel":"","context":"In &quot;d3&quot;","block_context":{"text":"d3","link":"https:\/\/rud.is\/b\/category\/d3\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/2046","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/comments?post=2046"}],"version-history":[{"count":0,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/2046\/revisions"}],"wp:attachment":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/media?parent=2046"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/categories?post=2046"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/tags?post=2046"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}