preprocess_map {cartographr}R Documentation

Preprocess OSM Data

Description

This function preprocesses OpenStreetMap (OSM) data for further analysis and visualization. It filters and organizes data related to streets, railways, buildings, water bodies, green areas, beaches, and parking areas.

Usage

preprocess_map(osm)

Arguments

osm

A list containing OSM data elements.

Details

The function performs the following steps:

It returns the original OSM list with additional elements for each category of data and combined multipolygons for easy plotting.

Value

A list with preprocessed OSM data elements, including streets, railways, buildings, water bodies, green areas, beaches, and parking areas, each as separate list elements. Also includes a combined multipolygon for water, buildings, and green areas for plotting.

Examples

data("osm")
preprocessed_osm <- osm |> preprocess_map()

[Package cartographr version 0.2.2 Index]