On the 1st of July, Shanghai started enforcing its compulsory domestic waste management, which is the country’s very first to start the regulation. The city’s regulation requires people to sort trash into four categories – dry garbage, wet garbage (kitchen waste), recyclables and hazardous waste.
Although some resources have already listed out things belong to four categories, it is still hard for residents to get the gist of the waste sorting because sometimes. Therefore, instead of text, we decided to visualize it.
The project was widely shared by our users, and it was viewed more than 200,000 times on our own platform.
1) We scraped a list of all 2055 items from the local government’s public database.
2) We made the visualization using P5.js and D3.js
What was the hardest part of this project?
The whole project was finished within five days. The tight schedule force us to make each step as precise and efficient as possible.
What can others learn from this project?
Under the new rule, different parts or usages of items could lead to different waste sorting. For instance, glass bottles of milk are recyclables waste while the same containers of medicine are hazardous. We scraped a list of all 2055 items from the local government’s public database. To make things clear, we applied five colors to four categories of waste mentioned above and non-domestic wastes. Then, we colored 2055 things and grouped them into 47 queries.
Each ball of the visualization represents one query group of items, like packing materials, cups, pens, metals, and more. The colors of the ball are a mixture of the color of every single thing of the query group. The more evidence of one color, the more likely the query group belong to a waste category. For example, the ball of electronics is almost covered by blue, so we learned that most electronics are recyclable. Seeing the visualization, readers can instantly get the whole picture of waste sorting. If they are especially interested in one query group, they can click on the ball and check the attribute of every item.