Category Archives: D3js

Visualizing web page views using D3js

In this post I am going to show you a Data Visualization using web page view data which is the number of web page views in every month for the year 2014. I have downloaded the data in a csv format and after a bit of cleansing the data file, it looks as below.

"MonthName","PageViews"
"Jan","1646"
"Feb","1143"
"Mar","1643"
"Apr","1591"
"May","1645"
"Jun","2082"
"Jul","2633"
"Aug","3035"
"Sep","2882"
"Oct","2900"
"Nov","2780"
"Dec","2448"

Continue reading

How domain and range works in D3js

When you are working with Scale functions in D3, there you need a domain and range to map the data values from an input domain to an output range, which means range of possible input data values to range of possible output values.

Below is the basic example to understand the domain and range.

Suppose you have a dataset like [100, 200, 300, 400, 500, 600] and you need to visualize each data to width of one bar into a canvas of 500px width and height. Code will look like as below.

Continue reading

A brief introduction to D3js Data Visualization

D3.js is a JavaScript library which helps you to create amazing data visualization using HTML, SVG and CSS by leveraging existing web standards and it supports and gives full access to all modern browsers as well as that of Android and iOS. D3 refers to Data-Driven Documents. Today it is a most popular web based data visualization technology in the world.

Since last couple of weeks I am learning D3, so you can say I am a beginner to the D3. Here I am going to show you a very basic Data Visualization example.

Continue reading