Skip to content

Update the example for plotting data points of various colors #470

@seisman

Description

@seisman

Description of the problem

In the last plotting example in https://www.pygmt.org/latest/tutorials/plot.html, color=data.depth_km / data.depth_km.max() is passed to Figure.plot because makecpt wasn't implemented at that time.

We normalize the data values given to color because, by default, plot can only interpret values between 0 and 1. To use the actual data values, we would need to create a color palette table (CPT) which isn’t implemented yet.

Now we already can create a CPT file using pygmt.makecpt and we should rewrite the example using pygmt.makecpt.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationgood first issueGood for newcomershelp wantedHelping hands are appreciated

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions