Closed weiji14 closed 4 years ago
Add a check in the kwargs_to_strings
decorator?https://github.com/GenericMappingTools/pygmt/blob/2ddbb0e1977af85bf6a6ac63d7cbac9da3d08f05/pygmt/helpers/decorators.py#L244
I'm wondering if this functionality is specific to plot
only, or if there are other places which can take datetime-like 'region' arguments.
Almost any modules can accept datetime-like region, for example, basemap, histogram, and even grdimage (maybe, but never tried).
Ok, the extra 'datetime' check might slow things down by a bit, but since it's only checking for 4 (or 6) items in a list, it should be fine.
Description of the desired feature
Support passing in 'datetime' like inputs into the 'region' or '-R' argument in
plot
.Originally posted by @seisman in https://github.com/GenericMappingTools/pygmt/pull/464#issuecomment-636585247
Minimal working example:
The error message is:
This workaround does work, but it's cumbersome:
produces:
Are you willing to help implement and maintain this feature? Yes, but where should this code logic go?