Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

plot and plot3d: Allow passing a numpy array as intensity #891

Closed
seisman opened this issue Feb 14, 2021 · 2 comments
Closed

plot and plot3d: Allow passing a numpy array as intensity #891

seisman opened this issue Feb 14, 2021 · 2 comments
Labels
feature request New feature wanted
Milestone

Comments

@seisman
Copy link
Member

seisman commented Feb 14, 2021

If using intensity=True, we will instead read intens from the first data column after the symbols parameters.

As I understand it, there are at least three or four different ways to specify an intensity/intensities.

  • Simply give a constant intensity like intensity=0.5
  • Pass a numpy array to intensity (similar to the x, y, size parameters): I think it's not implemented yet
  • Set intensity=True, and read data from an input file or from a 2D numpy array (via the data parameter).

The format of the input file of plot is (https://docs.generic-mapping-tools.org/latest/plot.html#s):

x y [ z ] [ size ] [ symbol-parameters ] [ symbol ]

So, for the 3rd case, the format of the input file should be:

x y [ z ] [ size ] [ symbol-parameters ] intensity [ symbol ]

Originally posted by @seisman in #881 (comment)

@core-man
Copy link
Member

core-man commented Mar 2, 2021

I'd like to help with this issue.

@seisman
Copy link
Member Author

seisman commented Mar 24, 2021

Implemented in #1065 and #1109.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature wanted
Projects
None yet
Development

No branches or pull requests

2 participants