Coding Challenge #57: Mapping Earthquake Data
In this coding challenge, I visualize earthquake data from the USGS by mapping the latitude, longitude and the magnitude of earthquakes with p5.js. The map imagery is pulled from mapbox and the math demonstrated converts latitude, longitude to x,y via Web Mercator. Code: https://thecodingtrain.com/challenges/57-mapping-earthquake-data
๐น๏ธ p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/sketches/i0icLNOuf
๐ฅ Previous video: https://youtu.be/OAcXnzRNiCY?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
๐ฅ Next video: https://youtu.be/dbs4IYGfAXc?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
๐ฅ All videos: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
References:
๐บ๏ธ Mapbox: https://www.mapbox.com/
๐ Web Mercator on Wikipedia: https://en.wikipedia.org/wiki/Web_Mercator
๐ Earthquake Database: http://earthquake.usgs.gov/data/
Videos:
๐ Working with Data and APIs: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6YxDKpFzf_2D84p0cyk4T7X
๐ฃ Regular Expressions Series: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6YEypLuls7iidwHMdCM6o2w
Related Coding Challenges:
๐ 58 3D Earthquake Data Visualization: https://youtu.be/dbs4IYGfAXc
Timestamps:
00:00 Introduction
01:51 Map Projections
04:45 Using the Mapbox Static Map
06:34 Adjusting the parameters to get a World Map
08:48 Latitudes and Longitudes
11:13 Converting Coordinates to pixel space
16:38 Drawing a point on the map
20:39 Loading and parsing earthquake data from USGS
26:05 Ideas and Suggestions
26:38 Drawing the size of point based on magnitude of earthquake
32:48 More Suggestions and Wrapping Up
Editing by Mathieu Blanchette
Animations by Jason Heglund
Music from Epidemic Sound
๐ Website: http://thecodingtrain.com/
๐พ Share Your Creation! https://thecodingtrain.com/guides/passenger-showcase-guide
๐ฉ Suggest Topics: https://github.com/CodingTrain/Suggestion-Box
๐ก GitHub: https://github.com/CodingTrain
๐ฌ Discord: https://thecodingtrain.com/discord
๐ Membership: http://youtube.com/thecodingtrain/join
๐ Store: https://standard.tv/codingtrain
๐๏ธ Twitter: https://twitter.com/thecodingtrain
๐ธ Instagram: https://www.instagram.com/the.coding.train/
๐ฅ Coding Challenges: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
๐ฅ Intro to Programming: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6Zy51Q-x9tMWIv9cueOFTFA
๐ p5.js: https://p5js.org
๐ p5.js Web Editor: https://editor.p5js.org/
๐ Processing: https://processing.org
๐ Code of Conduct: https://github.com/CodingTrain/Code-of-Conduct
This description was auto-generated. If you see a problem, please open an issue: https://github.com/CodingTrain/thecodingtrain.com/issues/new
#earthquakedata #mapbox #mapping #mercatorprojection #p5js