Sample output from Andrew Brown’s excellent Minecraft Overviewer.
Minecraft Overviewer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
license: gpl-3.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script type="text/javascript" src="https://cdn.rawgit.com/simplegeo/polymaps/v2.2.0/polymaps.min.js"></script> | |
<style type="text/css"> | |
@import url("https://cdn.rawgit.com/simplegeo/polymaps/v2.2.0/examples/example.css"); | |
html, body { | |
height: 100%; | |
} | |
svg { | |
display: block; | |
} | |
</style> | |
</head> | |
<body> | |
<script type="text/javascript"> | |
var po = org.polymaps; | |
var map = po.map() | |
.container(document.body.appendChild(po.svg("svg"))) | |
.tileSize({x: 384, y: 384}) | |
.zoomRange([0, 5]) | |
.zoom(1) | |
.center({lat: -45, lon: 0}) | |
.add(po.interact()) | |
.add(po.hash()); | |
map.add(po.image() | |
.url(minecraft("http://graphics.stanford.edu/~mbostock/minecraft-sample", ".png"))); | |
map.add(po.compass() | |
.pan("none")); | |
function minecraft(path, ext) { | |
return function(c) { | |
var k = 1 << c.zoom; | |
if (c.column < 0 | |
|| c.column >= k | |
|| c.row < 0 | |
|| c.row >= k) return "about:blank"; | |
if (c.zoom) { | |
for (var url = [path], z = c.zoom - 1; z >= 0; --z) { | |
k = Math.pow(2, -z); | |
url.push("/", (~~(c.column * k) & 1) + ((~~(c.row * k) & 1) << 1)); | |
} | |
url.push(ext); | |
return url.join(""); | |
} | |
return path + "/base" + ext; | |
}; | |
} | |
</script> | |
</body> | |
</html> |
This "block" is broken. The reason and solution can be found here: http://stackoverflow.com/questions/17341122/link-and-execute-external-javascript-file-hosted-on-github
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, I'm trying to play with this (http://mbostock.github.io/d3/talk/20111116/bundle.html) example with my own data. which has csv file contents as below:
source_proj ,issue_link, destination_proj ,dest_issuetype
[Inactive] Eikon Collab MM - Insider iPhone,Bug to Story,[Inactive] Eikon Collab MM - Insider iPhone,Story
[Inactive] Eikon Collab MM - Insider iPhone,jira_subtask_link,[Inactive] Eikon Collab MM - Insider iPhone,Acceptance Test
[Inactive] Eikon Collab MM - Insider iPhone,jira_subtask_link,[Inactive] Eikon Collab MM - Insider iPhone,Task
an so on.
can you guide me how to implement this graph with these four attribute. how to have relationship with them?
source_proj ,issue_link, destination_proj ,dest_issuetype