Skip to content

Tutorial "Plotting data points": Add legend for size coding#4214

Merged
seisman merged 1 commit intomainfrom
add-tut-plot-legend
Nov 17, 2025
Merged

Tutorial "Plotting data points": Add legend for size coding#4214
seisman merged 1 commit intomainfrom
add-tut-plot-legend

Conversation

@yvonnefroehlich
Copy link
Member

@yvonnefroehlich yvonnefroehlich commented Nov 16, 2025

Description of proposed changes

So far we do not add a legend for the size-coding in the tutorial "Plotting data points". This PR extends the tutorial by adding such a legend via an io.StringIO object. There is also issue #3675 by @maxrjones suggesting to add an example showing how to create a legend for size-coding, as this can not be done automatically in GMT.

Fixes #

Preview: https://pygmt-dev--4214.org.readthedocs.build/en/4214/tutorials/basics/plot.html

Guidelines

Slash Commands

You can write slash commands (/command) in the first line of a comment to perform
specific operations. Supported slash command is:

  • /format: automatically format and lint the code

@yvonnefroehlich yvonnefroehlich added this to the 0.18.0 milestone Nov 16, 2025
@yvonnefroehlich yvonnefroehlich self-assigned this Nov 16, 2025
@yvonnefroehlich yvonnefroehlich added documentation Improvements or additions to documentation enhancement Improving an existing feature labels Nov 16, 2025
@seisman seisman removed the enhancement Improving an existing feature label Nov 17, 2025
Copy link
Member

@seisman seisman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

If I understand it correctly, issue #3675 can be closed?

@seisman seisman added the final review call This PR requires final review and approval from a second reviewer label Nov 17, 2025
@seisman seisman removed the final review call This PR requires final review and approval from a second reviewer label Nov 17, 2025
@seisman seisman changed the title DOC/Tutorial "Plotting data points": Add legend for size coding Tutorial "Plotting data points": Add legend for size coding Nov 17, 2025
@seisman seisman merged commit 9b11099 into main Nov 17, 2025
14 checks passed
@seisman seisman deleted the add-tut-plot-legend branch November 17, 2025 07:36
@yvonnefroehlich
Copy link
Member Author

If I understand it correctly, issue #3675 can be closed?

As PyGMT allows creating a legend via an io.StringIO object, I think including a size-coding legend in this tutorial is fine, and no separate example is needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants