GenericMappingTools / egu22pygmt

Crafting beautiful maps with PyGMT at EGU22
https://www.generic-mapping-tools.org/egu22pygmt
Creative Commons Attribution 4.0 International
32 stars 7 forks source link

Add the anatomy of a figure tutorial #7

Closed leouieda closed 2 years ago

leouieda commented 2 years ago

Create the notebook and add it to the TOC. Start with creating a figure and adding coast line elements to it.

weiji14 commented 2 years ago

To add a title with multiple words, you must use single quotes '' on the outer string and double quotes "" around the title

FYI, as of PyGMT v0.6.0 (https://github.com/GenericMappingTools/pygmt/pull/1487), spaces are allowed in the titles, i.e. "+tCoastlines around Japan" would work. So you can remove this important note :wink:

leouieda commented 2 years ago

I noticed while doing this actually! But the docs said that they were mandatory so I thought it might just be something about my setup. Good to know!

leouieda commented 2 years ago

Hi all, this is ready for a review. The content is probably a bit too much for 20 minutes but I think it will fit. I'll do a trial recording now to see how it goes. Any feedback would be appreciated. I can make a final recording later after feedback.

weiji14 commented 2 years ago

Looks pretty good! Just a couple of suggestions:

  1. Bring some of the headings up a level. I.e. make h2->h1 and h3->h2. E.g. instead of ### Adding minor ticks, do ## Adding minor ticks so that they show up on the right sidebar. Or if you know of a jupyter-book setting to show h3 headings, I'm all ears!
  2. I kinda feel like you could decrease the region's xmin a bit, maybe something like region = [125, 155, 30, 55] to make Japan a bit more centred in the middle of the map?
leouieda commented 2 years ago

Alright, made the changes suggested by @weiji14 (thanks!) and made a recording: https://www.dropbox.com/s/fsalumnpgzz4ix6/egu22-pygmt-first-figure.mp4?dl=0

It's at a little over 21 min. I can try to do some cuts to get it down to 20 min if needed. Any feedback would be great!

weiji14 commented 2 years ago

Alright, made the changes suggested by @weiji14 (thanks!) and made a recording: https://www.dropbox.com/s/fsalumnpgzz4ix6/egu22-pygmt-first-figure.mp4?dl=0

It's at a little over 21 min. I can try to do some cuts to get it down to 20 min if needed. Any feedback would be great!

The recording looks great, honestly couldn't find anything major to nitpick on, and I think you've explained the basic PyGMT/GMT concepts really well :smile: 21min should be ok for now, let's see how long the other presentations are and we can trim it to <= 20min if needed.

weiji14 commented 2 years ago

If you clear the notebook cells and push another commit, I can approve and get this merged into the main branch.

joa-quim commented 2 years ago

Hi Leo. Congrats, very nice tutorial indeed. I was surprised though with one part of it. When you painted the land in lightgreen with the single command fig.coast(land="lightgreen") the figure came out with both painted land and ocean. How is that possible?

leouieda commented 2 years ago

@weiji14 done 👍🏾

@joa-quim thanks! The figure is built dynamically so that call is adding to a pre-existing figure that already had the water. No magic there 🙂