tmap
tmap copied to clipboard
tmap_arrange -> patchwork-ish functionality
Dear tmap developers,
I have a question regarding the tmap_arrange() function and its ability to handle complex, multi-layered layouts. Specifically, I'm trying to recreate a layout similar to the image below:

https://www.thebrighterside.news/post/global-life-expectancy-forecast-to-rise-nearly-5-years-by-2050/
This layout features:
- A large world map occupying the majority of the space.
- A set of smaller maps arranged in two rows at the bottom.
- The first row contains 5 small maps of equal width.
- The second row contains 2 small maps, with the second one being wider than the first.
https://www.thelancet.com/journals/lanplh/article/PIIS2542-5196%2818%2930170-0/fulltext
This layout features:
- Two main world maps at the top, side by side, representing different datasets: "Energy availability" (A) and "Carbohydrate availability" (B).
- A series of smaller maps at the bottom, arranged in two rows, showcasing detailed views of specific regions.
- The first row contains 5 small maps of equal width.
- The second row contains 2 small maps, with the second one being wider than the first.
- Each main map and small map has its own legend and title, clearly indicating the dataset it represents.
I've been attempting to use nested tmap_arrange() calls to achieve this, but I'm encountering difficulties. I'm wondering:
- Does
tmap_arrange()support circular or multi-layered nesting to create such complex layouts? - What is the recommended approach to recreate the layout in the image using
tmap?
I've tried various combinations of tmap_arrange() with different nrow, widths, and heights parameters, but I haven't been able to achieve the desired result.
Any guidance or suggestions would be greatly appreciated.
Thank you for your time and assistance.
Best regards, Dainel Tse