pygmt
pygmt copied to clipboard
Inconsistent usage of 'function' and 'method'
It seems that the terms 'function' and 'method' are used exchangeable in the tutorial and gallery examples.
From my understanding, in Python a method belongs to a class and is associated with / called on an object. This is consistent to the API Documentation of the pygmt.Figure class.
However,
- there are examples which use 'function' for the methods of the
pygmt.Figureclass, e.g.:-
Making subplots: The
pygmt.Figure.subplotfunction
-
Making subplots: The
- there are examples which use 'method' for the tabular and raster data processing functions, e.g.:
-
Generate points along great circles: The
pygmt.projectmethod -
Create ‘wet-dry’ mask grid: The
pygmt.grdlandmaskmethod -
Blockmean: The
pygmt.blockmeanmethod
-
Generate points along great circles: The
I think, we should be precise and consistent with the terminology (at least in the way that something is always either a function or a method) to avoid confusions.
Good catch @yvonnefroehlich! Glad to review a PR for this if you want to submit a correction for these misnomers.
I try to work on this over time.