Fork me on GitHub

Learn JS Data

Data cleaning, manipulation, and wrangling in JavaScript

About this guide

This guide teaches the basics of manipulating data using JavaScript in the browser, or in node.js. Specifically, these tasks are geared around preparing data for further analysis and visualization.

This guide will demonstrate some basic techniques and how to implement them using core JavaScript API, the d3.js library and lodash.

It assumes you already have some basic knowledge of JavaScript.


This version of LearnJSData uses the now deprecated D3v3. For the most up-to-date version of this guide, Go Here.



Access this guide in:


Each document in this repo is executed when loaded into a browser. Check it out by opening the Developer Tools Console. You should see the output of the following code block:

console.log("This is the index!");

Check out the full source on github.


Is data cleaning and processing in JavaScript something you would actually want to do? Maybe.

There are other languages out there that do a great job with data wrangling:

These tools are great and you should use them. Often times, however, you are already familiar with a particular language (like JavaScript) and would like to get started with data, but want to take it one step at a time.

Additionally, sometimes you are already in a particular environment (like JavaScript) and don't have the luxury of switching to one of these other options.

In these cases, JavaScript could be considered a viable option for your data analysis. And if you find yourself in one of these situations, or just want to try out JavaScript for data analysis for fun, then this guide is for you!

Check out some of the tasks, and see if JavaScript Data something you want to try yourself.