How to reproduce an ArcGIS map projection with layers

Hello Watchers:

My intention is to produce something
similar to a question I presented a
colleague days ago THREAD that looks
like this:

image

The goal is two-fold:

  1. Highlight regions of interest within a
    country.
  2. Add annotations at centroids within those
    regions to explain certain characteristics of
    those regions.
    • An annotation in a card would be
      better for presentation purposes if
      possible.

Progress:

I am using Pluto, Julia v 1.7.*.
I have started pursuing the goal
with the following code:

NZL = GeoTables.gadm("NZL", children = true)
viz(NZL.geometry, decimation = 0.10, color = 1:nelements(NZL.geometry), 
    showboundary=true, colormap = :viridis)

I changed the decimation from 0.02 to 0.10
because the former had a skewed display
output. This code however is occupying a
bit of RAM after executing fairly quickly
initially. I have no background programs
running with the exception of some browser
tabs – yet the kernel run-time is at:

image

Presentation-level Question:

Are there any wrappers that allow for
interactive displays? (i.e., something
that might work similarly to PlotlyJS).

Disclaimer:

I have searched this listing here and understand the
general ideas about projections, coordinate systems,
and geographic data storage types.

However, these modules are not practical in my view.
They often use over-simplified examples, and do not
generally explain basic steps for importing or general
GeoJSON, .shp, .csv sources, for selecting appropriate
wrappers, or for achieving some level of presentation
quality for non-technical audiences.

A quick example with GMT (see more examples this example).
Texts give a little more work because you need to know the coordinates where to plot them.

using GMT

NZL = gadm("NZL", children=true);
plot(NZL, region=(166,179,-47.5,-34), proj=:guess, fill=:lightblue, lw=0.5)
plot!(gadm("NZL", "Canterbury"), fill=:blue, lw=0.5, show=true)

1 Like

@joa-quim Thank you!

This is practical and I appreciate your effort.

Regarding the text, as a starting point do
you think I should find a city in these provinces
to use as centroids then make subtle adjustments
to improve visibility?

Should I assign the text in the header of the code
block, then add to the plot function?

Thank you again,

From this answer I suspect that you failed to acknowledge that GMT.jl is a different package then Plots.

Yes, you can compute the centroids but the problems is that many districts have several polygons (just look at the several islands in the above plot) and thus some decision would have to be made on what centroid is the most representative. Then you can try the GMT.jl text module.

1 Like

Understood – are you receiving prompt
requesting GMTinstaller.exe to make
changes to your machine? The publisher
is unknown.

That’s GMT being installed. It changes the user’s path.

Alright, thank you –