Skip to main content
  • Agentic AI
  • AI Governance
  • Airflow
  • Anaconda
  • Apache Spark
  • Artificial Intelligence
  • Clustering
  • Dask
  • Data Science
  • Density-based clustering
  • dplyr
  • Factor analysis
  • Feature
  • Feature Engineering
  • Feature Extraction
  • Feature selection
  • Folium
  • GenomicRanges
  • ggmap
  • ggplot
  • Ground Truth
  • Hash table
  • Hyperparameter Tuning
  • Interpretability
  • Jupyter Notebook
  • Kubernetes
  • LLMOps
  • Machine Learning
  • Machine Learning Algorithms
  • MLOps
  • Model Drift
  • Model Evaluation
  • Model monitoring
  • Model Selection
  • Model Tuning
  • Overfitting
  • Plotly
  • PySpark
  • PyTorch
  • Responsible AI
  • Shiny (in R)
  • sklearn
  • spaCy
  • SR 26-2
  • Statistical Computing Environment (SCE)
  • TensorFlow
  • Underfitting
  • XGBoost
  • ggmap

    What is ggmap?

    ggmap is an R package that makes it easy to retrieve raster map tiles from popular online mapping services such as Google Maps and Stamen Maps, and plot them using the ggplot2 framework. The result is an easy, consistent and modular framework for spatial graphics with several tools for spatial data analysis.

    The basic idea driving ggmap is to take a downloaded map image, plot it as a contextual layer using ggplot2, and then plot additional content layers of data, statistics, or models on top of the map. In ggmap this process is broken into two pieces:

    1. Downloading the images and formatting them for plotting, done with get_map
    2. Making the plot with ggmap.

    qmap combines these two functions for quick map plotting, and qmplot attempts to wrap up the entire plotting process into one simple command.

    In addition, several utility functions are available in ggmap, which allow you to access the Google Geocoding, Distance Matrix, and Directions APIs.

    Example of a basic ggmap implementation

    Assuming you already have a data set in place on violent crimes in a city that corresponds with longitude and latitude fields, you can quickly plot it with qmplot:

    qmplot(lon, lat, data = violent_crimes, maptype = "toner-lite", color = I("red"))

    ggmap visualization

    ggmap visualization. Source: github

    Since ggmap is built on top of ggplot2, all your usual ggplot2 functionality (e.g., geoms, polishing, etc.) will work. ggplot2 also provides some unique graphing capabilities to your images within ggmap.

    Installation

    You can install ggmap from CRAN:

    install.packages("ggmap")

    library(ggmap)

    as well as from Github:

    if (!requireNamespace("devtools")) install.packages("devtools")

    devtools::install_github("dkahle/ggmap")

    Summary

    • Example of a basic ggmap implementation
    • Installation
    Domino's logo

    Who is Domino?

    Domino Data Lab empowers the largest AI-driven enterprises to build and operate AI at scale. Domino’s Enterprise AI Platform provides an integrated experience encompassing model development, MLOps, collaboration, and governance. With Domino, global enterprises can develop better medicines, grow more productive crops, develop more competitive products, and more. Founded in 2013, Domino is backed by Sequoia Capital, Coatue Management, NVIDIA, Snowflake, and other leading investors.

    Watch Demo
    • Platform

        • AI infrastructure
        • Data management
        • AI workbench
        • MLOps
        • AI governance
        • FinOps
        • Pricing
        • Security & compliance
        • What's new
    • Solutions

      • Industries

        • Life sciences
        • Finance
        • Public sector
        • Retail
        • Manufacturing
      • Use Cases

        • Generative AI
        • Cost-effective data science
        • Self-service data science
        • Model risk management
        • Cloud data science
    • Learn

        • Events
        • Blog
        • Podcast
        • Courses and certifications
        • Data Science Dictionary
        • Documentation
        • Support
        • Demo hub
    • Company

        • About
        • Why Domino
        • Careers
        • News and press
        • Partners
        • Customers
        • Contact us

    © 2026 Domino Data Lab, Inc. Made in San Francisco.

    • Do not sell my personal information
    • Privacy policy
    • Terms and conditions
    • Security
    • Legal
    Home
    Watch Demo
    Watch Demo