{"id":28,"date":"2013-04-22T22:43:58","date_gmt":"2013-04-22T20:43:58","guid":{"rendered":"http:\/\/andreikucharavy.com\/L3Cache\/?p=28"},"modified":"2014-03-16T23:50:50","modified_gmt":"2014-03-16T22:50:50","slug":"python-d3-js-integration","status":"publish","type":"post","link":"https:\/\/andreikucharavy.com\/L3Cache\/python-d3-js-integration\/","title":{"rendered":"Python &#8211; D3.js integration"},"content":{"rendered":"<p>Python provides a pretty coomon framework for biological data analysis. And D3.js is one of the most coomon plateforms for the visualisation of large massifs of data. So I have been looking for a way to make them work together. This post gives a pretty decent introduction to the d3.js visualisation for people totally unfamiliar with javascript. It also suggests a possible interfacting of d3.js with pyhton via a javascript pseudo-library for that is to be wrtitten to the root folder containing the html page in JSON format.<\/p>\n<p>An alternative approach is to is to send the JSON directly to a webpage javascript via the python build-in server, but this requires a little bit more work. In any case I will be looking more in depth at it shortly<\/p>\n<p><a style=\"line-height: 1.714285714; font-size: 1rem;\" href=\"http:\/\/blog.nextgenetics.net\/?e=7\">http:\/\/blog.nextgenetics.net\/?e=7<\/a><\/p>\n<p><em><strong>Update1:<\/strong>\u00a0<\/em>I tried to follow the path suggested in the link, it didn&#8217;t quite work for me<\/p>\n<p><em><strong>Update2:<\/strong><\/em> And as usual, the problem was not with the tutorial but with chair-keyboard interface on the users side: I put d3.min.js library in a folder my server had no permission to go, so it didn&#8217;t \u00a0get loaded and the script didn&#8217;t get executed. Using instead the following snippet to import the d3.min.js library works perfectly fine:<\/p>\n<pre><code>&lt;script src=\"http:\/\/d3js.org\/d3.v3.min.js\" charset=\"utf-8\"&gt;&lt;\/script&gt;r<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Python provides a pretty coomon framework for biological data analysis. And D3.js is one of the most coomon plateforms for the visualisation of large massifs of data. So I have been looking for a way to make them work together. This post gives a pretty decent introduction to the d3.js visualisation for people totally unfamiliar <a class=\"read-more\" href=\"https:\/\/andreikucharavy.com\/L3Cache\/python-d3-js-integration\/\">[&hellip;]<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[24],"tags":[10,11,9],"class_list":["post-28","post","type-post","status-publish","format-standard","hentry","category-prog","tag-bioinformatics","tag-dataviz","tag-programming"],"_links":{"self":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts\/28"}],"collection":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/comments?post=28"}],"version-history":[{"count":9,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts\/28\/revisions"}],"predecessor-version":[{"id":42,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts\/28\/revisions\/42"}],"wp:attachment":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/media?parent=28"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/categories?post=28"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/tags?post=28"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}