Products
Features
YouTube Video Summarizer
Summarize YouTube videos
Web & PDF Highlighter
Highlight web pages & PDFs
Chat with PDF
Ask any PDF questions with AI
Ask AI Clone
Chat with your highlights & memories
Audio Transcriber
Transcribe audio files to text
Glasp Reader
Read and highlight articles
Kindle Highlight Export
Export your Kindle highlights
Idea Hatch
Hatch ideas from your highlights
Integrations
Obsidian Plugin
Notion Integration
Pocket Integration
Instapaper Integration
Medium Integration
Readwise Integration
Snipd Integration
Hypothesis Integration
Apps & Extensions
Chrome Extension
Safari Extension
Edge Add-ons
Firefox Add-ons
iOS App
Android App
Discover
Discover
Ideas
Discover new ideas and insights
Articles
Curated articles and insights
Books
Book recommendations by great minds
Posts
Essays and notes from readers
Quotes
Inspiring quotes collection
Videos
Curated videos and summaries
Explore Glasp
Glasp Newsletter
Weekly insights and updates
Glasp Talk
Interview series with great minds
Glasp Blog
Latest news and articles
Glasp Use Cases
Learn how others use Glasp
Build & Support
Glasp API
Access Glasp's API for developers
MCP Connector
Connect Glasp to Claude & ChatGPT
Community
Glasp Reddit Community
Students
Student discount and benefits
FAQs
Frequently Asked Questions
AboutPricing
DashboardLog inSign up

7.4.6 R7. Visualization - Video 5: World Maps in R

December 13, 2018
by
MIT OpenCourseWare
YouTube video player
7.4.6 R7. Visualization - Video 5: World Maps in R

TL;DR

Learn how to use the ggmap package to plot a world map and visualize the number of international students from each country at MIT.

Transcript

So now we're going to try plotting a world map with a new data set that has the number of international students from each country. So first of all, we're going to need to use the ggmap package, which you may need to install. And we're going to load in the data set, which is called intlall.csv. So read.csv(intlall.csv). And I'm going to do stringsA... Read More

Key Insights

  • 🧑‍🎓 The ggmap package and the worldmap dataset can be used for effective visualization of international student data.
  • 🗺️ Cleaning and merging datasets are crucial steps in creating accurate and visually appealing world maps.
  • 📛 Resolving naming inconsistencies ensures that all relevant data is included in the visualization.

Install to Summarize YouTube Videos and Get Transcripts

Explore YouTube Video Summarizer or Get YouTube Transcript Extractor

Questions & Answers

Q: What are the key steps involved in plotting a world map with international student data?

The key steps are installing and loading the ggmap package, loading the intlall.csv data set, cleaning the data, merging the world map and international student data frames, reordering the data, fixing naming inconsistencies, and plotting the map with different projections.

Q: Why is it important to clean the data and convert NAs to 0s?

Converting NAs to 0s ensures that missing data points are properly accounted for when plotting the map. Otherwise, the missing values could affect the accuracy and appearance of the visualization.

Q: How can naming inconsistencies between the MIT data frame and the world map data frame be resolved?

By identifying the naming differences (e.g., "China (People's Republic Of)" vs. "China") and changing the inconsistent names in the MIT data frame to match the world_map data frame, the datasets can be merged properly.

Q: What are some alternative projections that can be used for plotting the world map?

Besides the Mercator projection, an orthographic projection allows for a 3D-like view of the map as if looking at a globe. Other projections, such as Robinson, Albers, or Conic, can also be explored for different visual perspectives.

Summary & Key Takeaways

  • Use the ggmap package to plot a world map and load the international student data set (intlall.csv).

  • Clean the data by converting NAs to 0s and merge the world map data frame with the international student data frame.

  • Reorder the data in the correct order to prevent misplacement of country borders.

  • Fix naming inconsistencies between the MIT data frame and the world map data frame (e.g., changing "China (People's Republic Of)" to "China").

  • Plot the world map with different projections, such as Mercator and orthographic.


Read in Other Languages (beta)

English

Share This Summary 📚

Summarize YouTube Videos and Get Video Transcripts with 1-Click

Download browser extensions on:

Try YouTube Summary with ChatGPT & Claude or YouTube Transcript Generator

Explore More Summaries from MIT OpenCourseWare 📚

Laplace Equation thumbnail
Laplace Equation
MIT OpenCourseWare
L13.8 A Simple Example thumbnail
L13.8 A Simple Example
MIT OpenCourseWare
Recitation 10: Quiz 1 Review thumbnail
Recitation 10: Quiz 1 Review
MIT OpenCourseWare

Summarize YouTube Videos and Get Video Transcripts with 1-Click

Download browser extensions on:

Try YouTube Summary with ChatGPT & Claude or YouTube Transcript Generator

Apps & Extensions

  • Chrome Extension
  • Safari Extension
  • Edge Add-ons
  • Firefox Add-ons
  • iOS App
  • Android App

Key Features

  • YouTube Video Summarizer
  • Web & PDF Summarizer
  • Web & PDF Highlighter
  • Chat with PDF
  • Ask AI Clone
  • Audio Transcriber
  • Glasp Reader
  • Kindle Highlight Export
  • Idea Hatch

Integrations

  • Obsidian Plugin
  • Notion Integration
  • Pocket Integration
  • Instapaper Integration
  • Medium Integration
  • Readwise Integration
  • Snipd Integration
  • Hypothesis Integration

More Features

  • APIs
  • MCP Connector
  • Blog & Post
  • Embed Links
  • Image Highlight
  • Personality Test
  • Quote Shots

Company

  • About us
  • Blog
  • Community
  • FAQs
  • Job Board
  • Newsletter
  • Pricing
Terms

•

Privacy

•

Guidelines

© 2026 Glasp Inc. All rights reserved.