1st Edition

JavaScript for Data Science

By Maya Gans, Toby Hodges, Greg Wilson Copyright 2020
    244 Pages
    by Chapman & Hall

    244 Pages
    by Chapman & Hall

    JavaScript is the native language of the Internet. Originally created to make web pages more dynamic, it is now used for software projects of all kinds, including scientific visualization and data services. However, most data scientists have little or no experience with JavaScript, and most introductions to the language are written for people who want to build shopping carts rather than share maps of coral reefs.

    This book will introduce you to JavaScript's power and idiosyncrasies and guide you through the key features of the language and its tools and libraries. The book places equal focus on client- and server-side programming, and shows readers how to create interactive web content, build and test data services, and visualize data in the browser. Topics include:

    • The core features of modern JavaScript
    • Creating templated web pages
    • Making those pages interactive using React
    • Data visualization using Vega-Lite
    • Using Data-Forge to wrangle tabular data
    • Building a data service with Express
    • Unit testing with Mocha

    All of the material is covered by the Creative Commons Attribution-Noncommercial 4.0 International license (CC-BY-NC-4.0) and is included in the book's companion website.


    Maya Gans is a freelance data scientist and front-end developer by way of quantitative biology. Toby Hodges is a bioinformatician turned community coordinator who works at the European Molecular Biology Laboratory. Greg Wilson co-founded Software Carpentry, and is now part of the education team at RStudio

    Introduction. Basic Features. Callbacks. Objects and Classes. HTML and CSS. Manipulating Pages. Dynamic Pages. Visualizing Data. Promises. Interactive Sites. Managing Data. Creating a Server. Testing. Capstone Project. Conclusion


    Toby Hodges is a bioinformatician turned community coordinator, working on the Bio-IT Project at EMBL. He teaches a lot of courses in computing, organizes a lot of communitybuilding events, listens to a lot of punk rock, and occasionally still finds time to write code and ride his bike. Toby would like to thank his wife for her support and patience while he swore about how annoying JavaScript is to debug. Greg Wilson has worked for 35 years in both industry and academia, and is the author or editor of several books on computing and two for children. He co-founded [Software Carpentry][carpentries], a non-profit organization that teaches basic computing skills to researchers, and is now part of the education team at RStudio.