Repository navigation
pygmt.blockmean/blockmedian/blockmode: Block average (x, y, z) data tables by mean, median, or mode estimation #4549
Copy link
Copy link
Closed
Labels
feature requestNew feature wantedNew feature wanted
Description
This issue serves as the central place for discussing and tracking the implementation of the blockmean, blockmedian, and blockmode methods in PyGMT. The issue will be closed when the initial implementation is complete. Progress is tracked at PyGMT: Wrapping GMT modules.
Documentation
blockmean
- GMT: https://docs.generic-mapping-tools.org/dev/blockmean.html
- GMT.jl: https://www.generic-mapping-tools.org/GMTjl_doc/documentation/modules/blockmean
- PyGMT: https://www.pygmt.org/dev/api/generated/pygmt.blockmean.html
blockmedian
- GMT: https://docs.generic-mapping-tools.org/dev/blockmedian.html
- GMT.jl: https://www.generic-mapping-tools.org/GMTjl_doc/documentation/modules/blockmedian
- PyGMT: https://www.pygmt.org/dev/api/generated/pygmt.blockmedian.html
blockmode
- GMT: https://docs.generic-mapping-tools.org/dev/blockmode.html
- GMT.jl: https://www.generic-mapping-tools.org/GMTjl_doc/documentation/modules/blockmode
- PyGMT: https://www.pygmt.org/dev/api/generated/pygmt.blockmode.html
GMT Option Flags and Modifiers
☑️: Implemented; ⬜: To be implemented/discussed; Strikethrough: Won't implement.
blockmean
-
-C: Report center of block as position instead of mean position -
-E: Estimate standard deviations (or median absolute deviations) per block -
-G: Write output to one or more grid files -
-I:spacing -
-R:region -
-S:summary -
-W: Input/output weights -
-V:verbose -
-a:aspatial -
-b:binary -
-d:nodata -
-e:find -
-f:coltypes -
-g:gap -
-h:header -
-i:incols -
-o:outcols -
-q:select_rows -
-r:registration -
-s:skiprows -
-w:wrap -
: Use-UFigure.timestampinstead. -
: Use-X/-YFigure.shift_origininstead. -
: Use--PAR=valuepygmt.configinstead.
blockmedian
-
-C: Report center of block as position instead of median position -
-E: Estimate median absolute deviations per block -
-G: Write output to one or more grid files -
-I:spacing -
-Q: No median checking (use with-E) -
-R:region -
-T: Select the L1 norm (MAD) instead of median -
-W: Input/output weights -
-V:verbose -
-a:aspatial -
-b:binary -
-d:nodata -
-e:find -
-f:coltypes -
-g:gap -
-h:header -
-i:incols -
-o:outcols -
-q:select_rows -
-r:registration -
-s:skiprows -
-w:wrap -
: Use-UFigure.timestampinstead. -
: Use-X/-YFigure.shift_origininstead. -
: Use--PAR=valuepygmt.configinstead.
blockmode
-
-C: Report center of block as position instead of mode position -
-D: Set bin width for LMS mode estimation -
-E: Estimate LMS sigma per block -
-G: Write output to one or more grid files -
-I:spacing -
-Q: Use quantile (not LMS) mode estimation -
-R:region -
-W: Input/output weights -
-V:verbose -
-a:aspatial -
-b:binary -
-d:nodata -
-e:find -
-f:coltypes -
-g:gap -
-h:header -
-i:incols -
-o:outcols -
-q:select_rows -
-r:registration -
-s:skiprows -
-w:wrap -
: Use-UFigure.timestampinstead. -
: Use-X/-YFigure.shift_origininstead. -
: Use--PAR=valuepygmt.configinstead.
Related GMT configurations
List any related GMT configurations that may affect the behavior.
Notes on Input Formats
The functions accept (x, y, z) data as:
- A path to an ASCII data table file
- A 2-D
numpy.ndarray - A
pandas.DataFrame - An
xarray.Dataset - Separate 1-D arrays for x, y, and z coordinates
Optionally, a fourth column of weights (w) may be provided when using -W.
Linked Pull Requests
- Initial feature implementation (Remove warnings and improve colorbar gallery example #596, Add common alias perspective (p) for plotting 3D illustrations #627, Improve documentation for +r option in the regions tutorial #1027)
- Add missing option flags (
-C,-E,-G,-W,-g,-q,-s, and module-specific flags) - Add a gallery example
Related Issues and Discussions
- Remove warnings and improve colorbar gallery example #596: Initial
blockmeanimplementation - Add common alias perspective (p) for plotting 3D illustrations #627: Initial
blockmedianimplementation - Improve documentation for +r option in the regions tutorial #1027: Initial
blockmodeimplementation
Metadata
Metadata
Assignees
Labels
feature requestNew feature wantedNew feature wanted
Type
Projects
- StatusShow more project fieldsNo status
Activity