Prepare JSON data for barchart in D3
This week you will make your first visualization in D3, but before you start to learn how D3 work, you will prepare your dataset first. The most convenient way to load your data with D3 is to use JSON format. Read this introduction to JSON and follow other links on w3school (like JSON data types, JSON objects) to make sure, that you know how the JSON format looks like and why it is handy to use it.
Find the dataset that you would like to show in a barchart. The preferable format is a csv file, but it can be any other format as long as it’s not JSON. You can use for example the KNMI webpage again to download the average monthly amount of rain in De Bilt in 2015. Do not scrape any data, this will take a lot of time, and it’s not the purpose of this assignment.
Convert the data into JSON format using python. Try to make your script as general as possible so that you can re-use it to format other datasets (will become useful in other assignments in this course, in the programming project and probably in other courses, where you need to manipulate data).
Create folder Week 3 in your Homework folder and push the following files:
- both datasets (.csv and .json)