The purpose of this project is to visually show the differences between the magnitudes of earthquakes all over the world for the last seven days. We used JavaScript and the D3.js library to retrieve the coordinates and magnitudes of the earthquakes from the GeoJSON earthquake data linked to the USGS website. To display our data, we used the Leaflet library to plot the data on a Mapbox map through an API request and create interactivity for the earthquake data.
VS Code 1.71.0
JavaScript
, CSS
, HTML
The earthquakes are categorized by size and color. The spectrum of color ranges from yellow (low-magnitude earthquakes) to red (high-magnitude earthquakes). Additionally, low-magnitude earthquakes have a small diameter and high-magnitude earthquakes are illustrated with a larger diameter.
The viewer can interact with the map to show three different views and filter between three layers:
View Options | Filter Options |
---|---|
- Street View | - All Earthquakes |
- Satellite View | - Tectonic Plates |
- Dark View | - Major Earthquakes |