Questions tagged [tmap]

tmap is an actively maintained open-source R-library for drawing thematic maps, written by Martijn Tennekes. The API is based on the Layered Grammar of Graphics, and resembles the syntax of ggplot2, a popular R-library for drawing charts.

tmap is an actively maintained open-source R-library for drawing thematic maps, written by Martijn Tennekes. The API is based on A Layered Grammar of Graphics by Hadley Wickham and resembles the syntax of , a popular R-library for drawing charts.

Repositories

Vignette

Presentation

Other resources

487 questions
1
vote
1 answer

Add histogram axis labels in legend histogram in tmap R

I would like to add axis labels to the legend histogram in tmap. Here is an example code: library(tmap) data(World) tm_shape(World) + tm_polygons("gdp_cap_est", style = "quantile", palette = "RdYlBu",legend.hist=TRUE) I am hoping to get…
1
vote
3 answers

How to apply a tmap variable to multiple output fields in Talend?

I'm working with tmap and I was wondering if it's possible to use this simple use case: I create a variable in central tmap section, and I apply the same variable to multiple output fields. In the above example, I have two String fields and I want…
1
vote
1 answer

How to concatenate datasets in Talend?

I would like to take two different datasets as an input and get the as an output the concatenation of the two datasets. There is a function in python pandas that do this job, called concat…
1
vote
1 answer

Make Tmap keep the same viewport when redrawing (R/Shiny)

I'd like to store the centre coordinates and zoom in Tmap so that when the map gets redrawn it uses the last known centre point and zoom level. The current behaviour is that it resets to the initial centre point and zoom level as per…
Polonium
  • 21
  • 4
1
vote
1 answer

Color points in tmap by date column

I am trying to color a set of geographical points by a time variable using the tmap function tm_dots, but it keeps treating the time variable as a categorical variable. Is there a way to use a POSIXct column as a continuous variable? Some example…
user3004015
  • 617
  • 1
  • 7
  • 14
1
vote
0 answers

Figure labels and references for tmap (leaflet) maps in a Shiny markdown document

Is it possible to create figure labels, and reference them within text, for interactive tmap objects in a R markdown that will be rendered/hosted using shiny runtime to make an interactive document? In a regular markdown report for a static map I…
BEVAN
  • 426
  • 2
  • 12
1
vote
1 answer

TALEND STUDIO - Get number of Non-working Days between start_date and end_date using TMAP in Talend

I am a beginner in Talend and I need to achieve the following: For example, I have two input tables in the TMAP component. Table 1: Start_Date End_Date 25/8/2022 1/9/2022 Table 2 (Lookup…
1
vote
1 answer

Plotting large sf dataframe

I need to work with a 10minutes (1/12th degree) global grid of all land areas. The grid is generated in R using package (sf). The grid is to be limited to land areas of the world. Grid ID is needed for further down-stream analysis. Code generating…
MJezierski
  • 11
  • 2
1
vote
0 answers

R tmap: Adjust line height in two-line legend title

Could you please help me with this problem? I want to put a legend title on two lines, and control legend placement in a figure that meets font size and figure size requirements. I am mapping a count variable to political units. Here, hopefully,…
Peter Pearman
  • 129
  • 1
  • 10
1
vote
1 answer

tmap_arrange output quality in R markdown

Is there any way to control the output resolution when using tmap_arrange? Example using the shape files of Dutch regions from the cbs api and assigning population data (random for simplicity). Each map on it's own is good quality. However, if I use…
Blaiso
  • 165
  • 9
1
vote
1 answer

Tmap using palette and different dataset

I would like to create a palette, my goal is to color the countries in proportion to how many meters they have in that country. How can I do it? This is my…
Lila
  • 72
  • 5
1
vote
1 answer

R tmap print Italy

I want to draw a map. The country that I need to pront is Italy and I use this code: library(sf) library(raster) library(dplyr) library(spData) library(spDataLarge) library(tmap) # for static and interactive maps library(leaflet) # for interactive…
Lila
  • 72
  • 5
1
vote
1 answer

Convert negative integer to string Talend open studio

My objective for this Talend Job is to insert the the data from excel into the mysql db. When i input the excel file, the column of Active Case is string which it contains some negative integer. However, i want to store this as in integer later in…
ButterJam
  • 11
  • 2
1
vote
1 answer

Tmap: school district map has been masked up with dark grey areas

Concerning my last post, I successfully plotted the school districts on a national map using the library tmap. Below is my attempt to plot the map. As you can see, this is far behind the reference (by Laura Bliss: Bloomberg CityLab, 2015) that I…
Kob
  • 147
  • 1
  • 11
1
vote
1 answer

Remove the outer boundary of the US using tidycensus, sf, and/or tmap packages

I downloaded the polygons for the contiguous United States from the tidycensus package. However, due to mapping needs, I would like to remove the outline of the US from the polygon, leaving the internal state borders only. Here is my…
z_11122
  • 153
  • 8