Tuesday, March 11, 2014

D3.js example





D3.js example
<!DOCTYPE html>
<html>
<head>
    <title>d3.js example 1</title>
    <script src="http://d3js.org/d3.v3.min.js"></script>
</head>
<body>
<h1>d3.js example 1</h1>
<script>
 d3.select("body").append("p").text("hello word");
 d3.select("body").append("svg").attr("width", 50).attr("height", 50).
 append("circle").attr("cx", 25).attr("cy", 25).attr("r", 25).style("fill", "purple");
   
</script>
                  
</body>
</html>

Result:


No comments:

Post a Comment