diff --git a/pygmt/figure.py b/pygmt/figure.py index e0ad3c2d47f..5f6740743df 100644 --- a/pygmt/figure.py +++ b/pygmt/figure.py @@ -209,10 +209,10 @@ def psconvert(self, **kwargs): anti_aliasing : str [**g**\|\ **p**\|\ **t**\][**1**\|\ **2**\|\ **4**]. Set the anti-aliasing options for **g**\ raphics or **t**\ ext. - Append the size of the subsample box (1, 2, or 4) [4]. [Default is - no anti-aliasing (same as bits = 1)]. + Append the size of the subsample box (1, 2, or 4) [Default is + ``"4"``]. [Default is no anti-aliasing (same as bits = 1).] fmt : str - Sets the output format, where **b** means BMP, **e** means EPS, + Set the output format, where **b** means BMP, **e** means EPS, **E** means EPS with PageSize command, **f** means PDF, **F** means multi-page PDF, **j** means JPEG, **g** means PNG, **G** means transparent PNG (untouched regions are transparent), **m** means @@ -273,21 +273,21 @@ def savefig( The desired figure file name, including the extension. See the list of supported formats and their extensions above. transparent : bool - If True, will use a transparent background for the figure. Only - valid for PNG format. + If ``True``, will use a transparent background for the figure. + Only valid for PNG format. crop : bool - If True, will crop the figure canvas (page) to the plot area. + If ``True``, will crop the figure canvas (page) to the plot area. anti_alias: bool - If True, will use anti aliasing when creating raster images (PNG, - JPG, TIFF). More specifically, it passes arguments ``t2`` + If ``True``, will use anti-aliasing when creating raster images + (PNG, JPG, TIFF). More specifically, it passes arguments ``t2`` and ``g2`` to the ``anti_aliasing`` parameter of :meth:`pygmt.Figure.psconvert`. Ignored if creating vector graphics. show: bool - If True, will open the figure in an external viewer. + If ``True``, will open the figure in an external viewer. dpi : int - Set raster resolution in dpi. Default is 720 for PDF, 300 for - others. + Set raster resolution in dpi [Default is ``720`` for PDF, ``300`` + for others]. **kwargs : dict Additional keyword arguments passed to :meth:`pygmt.Figure.psconvert`. Valid parameters are ``gs_path``, diff --git a/pygmt/helpers/decorators.py b/pygmt/helpers/decorators.py index adb1c6470e8..95a3c29db15 100644 --- a/pygmt/helpers/decorators.py +++ b/pygmt/helpers/decorators.py @@ -29,7 +29,7 @@ [**s**\|\ **S**]][**+l**\|\ **r**][**+p**\ *percent*]. Features with an area smaller than *min_area* in km\ :sup:`2` or of hierarchical level that is lower than *min_level* or higher than - *max_level* will not be plotted [Default is 0/0/4 (all + *max_level* will not be plotted [Default is ``"0/0/4"`` (all features)].""", "frame": r""" frame : bool or str or list @@ -305,13 +305,13 @@ [**x**\|\ **y**\|\ **z**]\ *azim*\[/*elev*\[/*zlevel*]]\ [**+w**\ *lon0*/*lat0*\[/*z0*]][**+v**\ *x0*/*y0*]. Select perspective view and set the azimuth and elevation angle of - the viewpoint. Default is [180, 90]. Full documentation is at + the viewpoint [Default is ``[180, 90]``]. Full documentation is at :gmt-docs:`gmt.html#perspective-full`. """, "registration": r""" registration : str **g**\|\ **p**. - Force gridline (**g**) or pixel (**p**) node registration. + Force gridline (**g**) or pixel (**p**) node registration [Default is **g**\ (ridline)]. """, "skiprows": r""" @@ -333,7 +333,7 @@ "transparency": r""" transparency : int or float Set transparency level, in [0-100] percent range - [Default is 0, i.e., opaque]. + [Default is ``0``, i.e., opaque]. Only visible when PDF or raster format output is selected. Only the PNG format selection adds a transparency layer in the image (for further processing). """, diff --git a/pygmt/src/basemap.py b/pygmt/src/basemap.py index 4896e9955d0..32f12782da0 100644 --- a/pygmt/src/basemap.py +++ b/pygmt/src/basemap.py @@ -54,11 +54,11 @@ def basemap(self, **kwargs): map_scale : str [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ **+w**\ *length*. - Draws a simple map scale centered on the reference point specified. + Draw a simple map scale centered on the reference point specified. box : bool or str [**+c**\ *clearances*][**+g**\ *fill*][**+i**\ [[*gap*/]\ *pen*]]\ [**+p**\ [*pen*]][**+r**\ [*radius*]][**+s**\ [[*dx*/*dy*/][*shade*]]]. - If set to ``True``, draws a rectangular border around the + If set to ``True``, draw a rectangular border around the map scale or rose. Alternatively, specify a different pen with **+p**\ *pen*. Add **+g**\ *fill* to fill the scale panel [Default is no fill]. Append **+c**\ *clearance* where *clearance* is either gap, @@ -71,14 +71,14 @@ def basemap(self, **kwargs): radius. You can override this radius by appending another value. Finally, append **+s** to draw an offset background shaded region. Here, *dx/dy* indicates the shift relative to the foreground frame - [Default is 4p/-4p] and shade sets the fill style to use for shading - [Default is gray50]. + [Default is ``"4p/-4p"``] and shade sets the fill style to use for + shading [Default is ``"gray50"``]. rose : str - Draws a map directional rose on the map at the location defined by + Draw a map directional rose on the map at the location defined by the reference and anchor points. compass : str - Draws a map magnetic rose on the map at the location defined by the - reference and anchor points + Draw a map magnetic rose on the map at the location defined by the + reference and anchor points. {verbose} {panel} {coltypes} diff --git a/pygmt/src/binstats.py b/pygmt/src/binstats.py index ecc3e160d98..68f8996b39f 100644 --- a/pygmt/src/binstats.py +++ b/pygmt/src/binstats.py @@ -84,7 +84,7 @@ def binstats(data, **kwargs): Normalize the resulting grid values by the area represented by the search *radius* [no normalization]. search_radius : float or str - Sets the *search_radius* that determines which data points are + Set the *search_radius* that determines which data points are considered close to a node. Append the distance unit. Not compatible with ``tiling``. weight : str diff --git a/pygmt/src/coast.py b/pygmt/src/coast.py index c89a6a9aa71..a9a5908bf37 100644 --- a/pygmt/src/coast.py +++ b/pygmt/src/coast.py @@ -76,7 +76,7 @@ def coast(self, **kwargs): strings in a list. resolution : str **f**\|\ **h**\|\ **i**\|\ **l**\|\ **c**. - Selects the resolution of the data set to: (**f**\ )ull, + Select the resolution of the data set to: (**f**\ )ull, (**h**\ )igh, (**i**\ )ntermediate, (**l**\ )ow, and (**c**\ )rude. land : str @@ -127,7 +127,7 @@ def coast(self, **kwargs): map_scale : str [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ **+w**\ *length*. - Draws a simple map scale centered on the reference point specified. + Draw a simple map scale centered on the reference point specified. borders : int or str or list *border*\ [/*pen*]. Draw political boundaries. Specify the type of boundary and diff --git a/pygmt/src/colorbar.py b/pygmt/src/colorbar.py index f2f67418bf3..1a65a3b417e 100644 --- a/pygmt/src/colorbar.py +++ b/pygmt/src/colorbar.py @@ -54,7 +54,7 @@ def colorbar(self, **kwargs): [**+h**\|\ **v**][**+j**\ *justify*]\ [**+m**\ [**a**\|\ **c**\|\ **l**\|\ **u**]]\ [**+n**\ [*txt*]][**+o**\ *dx*\ [/*dy*]]. - Defines the reference point on the map for the color scale using one of + Define the reference point on the map for the color scale using one of four coordinate systems: (1) Use **g** for map (user) coordinates, (2) use **j** or **J** for setting *refpoint* via a 2-character justification code that refers to the (invisible) map domain rectangle, @@ -71,7 +71,7 @@ def colorbar(self, **kwargs): box : bool or str [**+c**\ *clearances*][**+g**\ *fill*][**+i**\ [[*gap*/]\ *pen*]]\ [**+p**\ [*pen*]][**+r**\ [*radius*]][**+s**\ [[*dx*/*dy*/][*shade*]]]. - If set to ``True``, draws a rectangular border around the color scale. + If set to ``True``, draw a rectangular border around the color scale. Alternatively, specify a different pen with **+p**\ *pen*. Add **+g**\ *fill* to fill the scale panel [Default is no fill]. Append **+c**\ *clearance* where *clearance* is either gap, xgap/ygap, or diff --git a/pygmt/src/contour.py b/pygmt/src/contour.py index 8f0d4c59d00..eb5def52940 100644 --- a/pygmt/src/contour.py +++ b/pygmt/src/contour.py @@ -83,13 +83,13 @@ def contour(self, data=None, x=None, y=None, z=None, **kwargs): I : bool Color the triangles using CPT. triangular_mesh_pen : str - Pen to draw the underlying triangulation [Default is None]. + Pen to draw the underlying triangulation [Default is ``None``]. no_clip : bool - Do NOT clip contours or image at the boundaries [Default will clip - to fit inside region]. + Do **not** clip contours or image at the frame boundaries + [Default is ``False`` to fit inside ``region``]. Q : float or str [*cut*][**+z**]. - Do not draw contours with less than cut number of points. + Do not draw contours with less than *cut* number of points. skip : bool or str [**p**\|\ **t**]. Skip input points outside region. diff --git a/pygmt/src/dimfilter.py b/pygmt/src/dimfilter.py index 23348e4e9e6..ba4e39ce1bd 100644 --- a/pygmt/src/dimfilter.py +++ b/pygmt/src/dimfilter.py @@ -77,7 +77,7 @@ def dimfilter(grid, **kwargs): calculation. filter : str **x**\ *width*\ [**+l**\|\ **u**]. - Sets the primary filter type. Choose among convolution and + Set the primary filter type. Choose among convolution and non-convolution filters. Use the filter code **x** followed by the full diameter *width*. Available convolution filters are: @@ -94,7 +94,7 @@ def dimfilter(grid, **kwargs): to return the smallest or largest of each sector's modal values. sectors : str **x**\ *sectors*\ [**+l**\|\ **u**] - Sets the secondary filter type **x** and the number of bow-tie sectors. + Set the secondary filter type **x** and the number of bow-tie sectors. *sectors* must be integer and larger than 0. When *sectors* is set to 1, the secondary filter is not effective. Available secondary filters **x** are: @@ -108,14 +108,14 @@ def dimfilter(grid, **kwargs): value. Append **+l** or **+h** to the sectors if you rather want to return the smallest or largest of the modal values. spacing : str or list - *x_inc* [and optionally *y_inc*] is the output Increment. Append + *x_inc* [and optionally *y_inc*] is the output increment. Append **m** to indicate minutes, or **c** to indicate seconds. If the new *x_inc*, *y_inc* are NOT integer multiples of the old ones (in the - input data), filtering will be considerably slower. [Default: Same + input data), filtering will be considerably slower. [Default is same as input.] region : str or list [*xmin*, *xmax*, *ymin*, *ymax*]. - Defines the region of the output points. [Default: Same as input.] + Define the region of the output points [Default is same as input]. {verbose} Returns diff --git a/pygmt/src/filter1d.py b/pygmt/src/filter1d.py index 5f15244d824..cc189a53053 100644 --- a/pygmt/src/filter1d.py +++ b/pygmt/src/filter1d.py @@ -35,7 +35,7 @@ def filter1d(data, output_type="pandas", outfile=None, **kwargs): ---------- filter_type : str **type**\ *width*\ [**+h**]. - Sets the filter **type**. Choose among convolution and non-convolution + Set the filter **type**. Choose among convolution and non-convolution filters. Append the filter code followed by the full filter *width* in same units as time column. By default, this performs a low-pass filtering; append **+h** to select high-pass @@ -82,9 +82,9 @@ def filter1d(data, output_type="pandas", outfile=None, **kwargs): half the filter-width of data at each end. time_col : int - Indicates which column contains the independent variable (time). The + Indicate which column contains the independent variable (time). The left-most column is 0, while the right-most is (*n_cols* - 1) - [Default is 0]. + [Default is ``0``]. output_type : str Determine the format the xyz data will be returned in [Default is diff --git a/pygmt/src/grd2cpt.py b/pygmt/src/grd2cpt.py index dd847a5fcbb..8d95caaef63 100644 --- a/pygmt/src/grd2cpt.py +++ b/pygmt/src/grd2cpt.py @@ -78,11 +78,11 @@ def grd2cpt(grid, **kwargs): grid : str or xarray.DataArray The file name of the input grid or the grid loaded as a DataArray. transparency : int or float or str - Sets a constant level of transparency (0-100) for all color slices. + Set a constant level of transparency (0-100) for all color slices. Append **+a** to also affect the foreground, background, and NaN - colors [Default is no transparency, i.e., 0 (opaque)]. + colors [Default is no transparency, i.e., ``0`` (opaque)]. cmap : str - Selects the master color palette table (CPT) to use in the + Select the master color palette table (CPT) to use in the interpolation. Full list of built-in color palette tables can be found at :gmt-docs:`cookbook/cpts.html#built-in-color-palette-tables-cpt`. background : bool or str @@ -111,10 +111,10 @@ def grd2cpt(grid, **kwargs): to resample the color table into *nlevels* equidistant slices. series : list or str [*min/max/inc*\ [**+b**\|\ **l**\|\ **n**\]|\ *file*\|\ *list*\]. - Defines the range of the new CPT by giving the lowest and highest + Define the range of the new CPT by giving the lowest and highest z-value (and optionally an interval). If this is not given, the existing range in the master CPT will be used intact. The values - produced defines the color slice boundaries. If **+n** is used it + produced defines the color slice boundaries. If **+n** is used it refers to the number of such boundaries and not the number of slices. For details on array creation, see :gmt-docs:`makecpt.html#generate-1d-array`. diff --git a/pygmt/src/grdgradient.py b/pygmt/src/grdgradient.py index 66c4930bbcf..932d73d5fa3 100644 --- a/pygmt/src/grdgradient.py +++ b/pygmt/src/grdgradient.py @@ -125,15 +125,15 @@ def grdgradient(grid, **kwargs): all nodes after gradient calculations are completed. tiles : str **c**\|\ **r**\|\ **R**. - Controls how normalization via ``normalize`` is carried out. When - multiple grids should be normalized the same way (i.e., with the same - *offset* and/or *sigma*), - we must pass these values via ``normalize``. However, this is - inconvenient if we compute these values from a grid. Use **c** to - save the results of *offset* and *sigma* to a statistics file; if - grid output is not needed for this run then do not specify - ``outgrid``. For subsequent runs, just use **r** to read these - values. Using **R** will read then delete the statistics file. + Control how normalization via ``normalize`` is carried out. When + multiple grids should be normalized the same way (i.e., with the same + *offset* and/or *sigma*), + we must pass these values via ``normalize``. However, this is + inconvenient if we compute these values from a grid. Use **c** to + save the results of *offset* and *sigma* to a statistics file; if + grid output is not needed for this run then do not specify + ``outgrid``. For subsequent runs, just use **r** to read these + values. Using **R** will read then delete the statistics file. {region} slope_file : str Name of output grid file with scalar magnitudes of gradient vectors. diff --git a/pygmt/src/grdhisteq.py b/pygmt/src/grdhisteq.py index 0171a644fa0..bdadae77cb0 100644 --- a/pygmt/src/grdhisteq.py +++ b/pygmt/src/grdhisteq.py @@ -84,10 +84,10 @@ def _grdhisteq(grid, output_type, **kwargs): The name of the output ASCII file to store the results of the histogram equalization in. output_type: str - Determines the output type. Use "file", "xarray", "pandas", or + Determine the output type. Use "file", "xarray", "pandas", or "numpy". divisions : int - Set the number of divisions of the data range [Default is 16]. + Set the number of divisions of the data range [Default is ``16``]. {region} {verbose} diff --git a/pygmt/src/grdimage.py b/pygmt/src/grdimage.py index 1640bfc65be..ad00dc96f56 100644 --- a/pygmt/src/grdimage.py +++ b/pygmt/src/grdimage.py @@ -112,11 +112,12 @@ def grdimage(self, grid, **kwargs): to project a raw image (an image without referencing coordinates). dpi : int [**i**\|\ *dpi*]. - Sets the resolution of the projected grid that will be created if a - map projection other than Linear or Mercator was selected [100]. By - default, the projected grid will be of the same size (rows and - columns) as the input file. Specify **i** to use the PostScript - image operator to interpolate the image at the device resolution. + Set the resolution of the projected grid that will be created if a + map projection other than Linear or Mercator was selected [Default + is ``100`` dpi]. By default, the projected grid will be of the + same size (rows and columns) as the input file. Specify **i** to + use the PostScript image operator to interpolate the image at the + device resolution. bit_color : str *color*\ [**+b**\|\ **f**\]. This parameter only applies when a resulting 1-bit image otherwise @@ -145,8 +146,8 @@ def grdimage(self, grid, **kwargs): Force conversion to monochrome image using the (television) YIQ transformation. Cannot be used with ``nan_transparent``. no_clip : bool - Do not clip the image at the map boundary (only relevant for - non-rectangular maps). + Do **not** clip the image at the frame boundaries (only relevant + for non-rectangular maps) [Default is ``False``]. nan_transparent : bool Make grid nodes with z = NaN transparent, using the color-masking feature in PostScript Level 3 (the PS device must support PS Level diff --git a/pygmt/src/grdinfo.py b/pygmt/src/grdinfo.py index 753c1e1dc30..d7945e70185 100644 --- a/pygmt/src/grdinfo.py +++ b/pygmt/src/grdinfo.py @@ -43,7 +43,7 @@ def grdinfo(grid, **kwargs): {region} per_column : str or bool **n**\|\ **t**. - Formats the report using tab-separated fields on a single line. The + Format the report using tab-separated fields on a single line. The output is name *w e s n z0 z1 dx dy nx ny* [ *x0 y0 x1 y1* ] [ *med scale* ] [ *mean std rms* ] [ *n_nan* ] *registration gtype*. The data in brackets are outputted depending on the ``force_scan`` diff --git a/pygmt/src/grdlandmask.py b/pygmt/src/grdlandmask.py index 8e6415cff0e..aab9bd0913a 100644 --- a/pygmt/src/grdlandmask.py +++ b/pygmt/src/grdlandmask.py @@ -52,7 +52,7 @@ def grdlandmask(**kwargs): {region} {area_thresh} resolution : str - *res*\[\ **+f**\]. Selects the resolution of the data set to use + *res*\[\ **+f**\]. Select the resolution of the data set to use ((**f**)ull, (**h**)igh, (**i**)ntermediate, (**l**)ow, or (**c**)rude). The resolution drops off by ~80% between data sets. [Default is **l**]. Append **+f** to automatically select a lower @@ -77,7 +77,7 @@ def grdlandmask(**kwargs): ponds-in-islands-in-lakes outlines [Default is no line tracing]. maskvalues : str or list [*wet*, *dry*] or [*ocean*, *land*, *lake*, *island*, *pond*]. - Sets the values that will be assigned to nodes. Values can + Set the values that will be assigned to nodes. Values can be any number, including the textstring NaN [Default is [0, 1, 0, 1, 0] (i.e., [0, 1])]. Also select ``bordervalues`` to let nodes exactly on feature boundaries be diff --git a/pygmt/src/grdview.py b/pygmt/src/grdview.py index 9f9d932e90e..e7bb5175503 100644 --- a/pygmt/src/grdview.py +++ b/pygmt/src/grdview.py @@ -77,11 +77,11 @@ def grdview(self, grid, **kwargs): (if drapegrid is a grid) will be looked-up via the CPT (see ``cmap``). plane : float or str *level*\ [**+g**\ *fill*]. - Draws a plane at this z-level. If the optional color is provided + Draw a plane at this z-level. If the optional color is provided via the **+g** modifier, and the projection is not oblique, the frontal facade between the plane and the data perimeter is colored. surftype : str - Specifies cover type of the grid. + Specify cover type of the grid. Select one of following settings: - **m** - mesh plot [Default]. @@ -97,10 +97,10 @@ def grdview(self, grid, **kwargs): Draw contour lines on top of surface or mesh (not image). Append pen attributes used for the contours. meshpen : str - Sets the pen attributes used for the mesh. You must also select + Set the pen attributes used for the mesh. You must also select ``surftype`` of **m** or **sm** for meshlines to be drawn. facadepen :str - Sets the pen attributes used for the facade. You must also select + Set the pen attributes used for the facade. You must also select ``plane`` for the facade outline to be drawn. shading : str Provide the name of a grid file with intensities in the (-1,+1) diff --git a/pygmt/src/histogram.py b/pygmt/src/histogram.py index 5cf8b4476fd..70a34d17008 100644 --- a/pygmt/src/histogram.py +++ b/pygmt/src/histogram.py @@ -100,7 +100,7 @@ def histogram(self, data, **kwargs): bin, use **l**, and to only include extreme values above the last bin into that last bin, use **h**. stairs : bool - Draws a stairs-step diagram which does not include the internal bars + Draw a stairs-step diagram which does not include the internal bars of the default histogram. horizontal : bool Plot the histogram using horizontal bars instead of the diff --git a/pygmt/src/image.py b/pygmt/src/image.py index 3852e02789f..f9dee878e5a 100644 --- a/pygmt/src/image.py +++ b/pygmt/src/image.py @@ -43,11 +43,11 @@ def image(self, imagefile, **kwargs): [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ **+r**\ *dpi*\ **+w**\ [**-**]\ *width*\ [/*height*]\ [**+j**\ *justify*]\ [**+n**\ *nx*\ [/*ny*] ]\ [**+o**\ *dx*\ [/*dy*]]. - Sets reference point on the map for the image. + Set reference point on the map for the image. box : bool or str [**+c**\ *clearances*][**+g**\ *fill*][**+i**\ [[*gap*/]\ *pen*]]\ [**+p**\ [*pen*]][**+r**\ [*radius*]][**+s**\ [[*dx*/*dy*/][*shade*]]]. - Without further arguments, draws a rectangular border around the image + If set to ``True``, draw a rectangular border around the image using :gmt-term:`MAP_FRAME_PEN`. monochrome : bool Convert color image to monochrome grayshades using the (television) diff --git a/pygmt/src/inset.py b/pygmt/src/inset.py index 1b65d424c1d..e28bdfac111 100644 --- a/pygmt/src/inset.py +++ b/pygmt/src/inset.py @@ -76,8 +76,7 @@ def inset(self, **kwargs): [**+c**\ *clearances*][**+g**\ *fill*][**+i**\ [[*gap*/]\ *pen*]][**+p**\ [*pen*]][**+r**\ [*radius*]][**+s**\ [[*dx*/*dy*/][*shade*]]]. - - If passed ``True``, this draws a rectangular box around the map + If set to ``True``, draw a rectangular box around the map inset using the default pen; specify a different pen with **+p**\ *pen*. Add **+g**\ *fill* to fill the logo box [Default is no fill]. @@ -91,9 +90,9 @@ def inset(self, **kwargs): rectangular borders instead, with a 6p corner radius. You can override this radius by appending another value. Append **+s** to draw an offset background shaded region. Here, *dx*/*dy* - indicates the shift relative to the foreground frame - [4p/-4p] and ``shade`` sets the fill style to use for - shading [Default is gray50]. + indicates the shift relative to the foreground frame [Default is + ``"4p/-4p"``] and ``shade`` sets the fill style to use for + shading [Default is ``"gray50"``]. margin : int or str or list This is clearance that is added around the inside of the inset. Plotting will take place within the inner region only. The margins @@ -104,8 +103,8 @@ def inset(self, **kwargs): a string with the values separated by forward slashes [Default is no margins]. no_clip : bool - Do NOT clip features extruding outside map inset boundaries [Default - is clip]. + Do **not** clip features extruding outside the inset frame + boundaries [Default is ``False``]. {region} {projection} {verbose} diff --git a/pygmt/src/legend.py b/pygmt/src/legend.py index ab195548c33..0a2d9da56d1 100644 --- a/pygmt/src/legend.py +++ b/pygmt/src/legend.py @@ -51,14 +51,14 @@ def legend(self, spec=None, position="JTR+jTR+o0.2c", box="+gwhite+p1p", **kwarg [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ **+w**\ *width*\ [/*height*]\ [**+j**\ *justify*]\ [**+l**\ *spacing*]\ [**+o**\ *dx*\ [/*dy*]]. - Defines the reference point on the map for the + Define the reference point on the map for the legend. By default, uses **JTR**\ **+jTR**\ **+o**\ 0.2c which places the legend at the top-right corner inside the map frame, with a 0.2 cm offset. box : bool or str [**+c**\ *clearances*][**+g**\ *fill*][**+i**\ [[*gap*/]\ *pen*]]\ [**+p**\ [*pen*]][**+r**\ [*radius*]][**+s**\ [[*dx*/*dy*/][*shade*]]]. - Without further arguments, draws a rectangular border around the legend + If set to ``True``, draw a rectangular border around the legend using :gmt-term:`MAP_FRAME_PEN`. By default, uses **+g**\ white\ **+p**\ 1p which draws a box around the legend using a 1p black pen and adds a white background. diff --git a/pygmt/src/logo.py b/pygmt/src/logo.py index 8e4e0dd7fe6..78b06c7e6a9 100644 --- a/pygmt/src/logo.py +++ b/pygmt/src/logo.py @@ -38,9 +38,9 @@ def logo(self, **kwargs): position : str [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ **+w**\ *width*\ [**+j**\ *justify*]\ [**+o**\ *dx*\ [/*dy*]]. - Sets reference point on the map for the image. + Set reference point on the map for the image. box : bool or str - Without further arguments, draws a rectangular border around the + If set to ``True``, draw a rectangular border around the GMT logo. style : str [**l**\|\ **n**\|\ **u**]. diff --git a/pygmt/src/makecpt.py b/pygmt/src/makecpt.py index 115eb088e47..9a188d20d0b 100644 --- a/pygmt/src/makecpt.py +++ b/pygmt/src/makecpt.py @@ -65,11 +65,11 @@ def makecpt(**kwargs): Parameters ---------- transparency : str - Sets a constant level of transparency (0-100) for all color slices. + Set a constant level of transparency (0-100) for all color slices. Append **+a** to also affect the foreground, background, and NaN - colors [Default is no transparency, i.e., 0 (opaque)]. + colors [Default is no transparency, i.e., ``0`` (opaque)]. cmap : str - Selects the master color palette table (CPT) to use in the + Select the master color palette table (CPT) to use in the interpolation. Full list of built-in color palette tables can be found at :gmt-docs:`cookbook/cpts.html#built-in-color-palette-tables-cpt`. background : bool or str @@ -94,7 +94,7 @@ def makecpt(**kwargs): build ranges *start*-*start+1* instead. series : list or str [*min/max/inc*\[**+b**\|\ **l**\|\ **n**]\|\ *file*\|\ *list*]. - Defines the range of the new CPT by giving the lowest and highest + Define the range of the new CPT by giving the lowest and highest z-value (and optionally an interval). If this is not given, the existing range in the master CPT will be used intact. The values produced defines the color slice boundaries. If **+n** is used it diff --git a/pygmt/src/meca.py b/pygmt/src/meca.py index 7556ea3f2c0..34d2e4ca60c 100644 --- a/pygmt/src/meca.py +++ b/pygmt/src/meca.py @@ -161,7 +161,7 @@ def meca( ``convention`` is not needed and is ignored if specified. scale : str - Adjusts the scaling of the radius of the beachball, which is + Adjust the scaling of the radius of the beachball, which is proportional to the magnitude. *scale* defines the size for magnitude = 5 (i.e. scalar seismic moment M0 = 4.0E23 dynes-cm). convention : str @@ -208,19 +208,19 @@ def meca( or pd.DataFrame. offset : bool or str [**+p**\ *pen*][**+s**\ *size*]. - Offsets beachball(s) to longitude(s) and latitude(s) specified in the + Offset beachball(s) to longitude(s) and latitude(s) specified in the the last two columns of the input file or array, or by ``plot_longitude`` and ``plot_latitude`` if provided. A small circle is plotted at the initial location and a line connects the beachball to the circle. Use **+s**\ *size* to set the diameter of the circle [Default is no circle]. Use **+p**\ *pen* to set the line pen - attributes [Default is 0.25p]. + attributes [Default is ``"0.25p"``]. compressionfill : str Set color or pattern for filling compressive quadrants - [Default is black]. + [Default is ``"black"``]. extensionfill : str Set color or pattern for filling extensive quadrants - [Default is white]. + [Default is ``"white"``]. pen : str Set pen attributes for outline of beachball [Default is ``"0.25p,black,solid"``]. @@ -231,8 +231,9 @@ def meca( determined by the z-value (i.e., event depth or the third column for an input file). no_clip : bool - Does NOT skip symbols that fall outside frame boundary specified by - ``region`` [Default is False, i.e. plot symbols inside map frame only]. + Do **not** skip symbols that fall outside the frame boundaries + [Default is ``False``, i.e., plot symbols inside the frame + boundaries only]. {projection} {region} {frame} diff --git a/pygmt/src/nearneighbor.py b/pygmt/src/nearneighbor.py index a1a15066aa0..2a0b63cdd9c 100644 --- a/pygmt/src/nearneighbor.py +++ b/pygmt/src/nearneighbor.py @@ -89,7 +89,7 @@ def nearneighbor(data=None, x=None, y=None, z=None, **kwargs): {region} search_radius : str - Sets the search radius that determines which data points are considered + Set the search radius that determines which data points are considered close to a node. outgrid : str diff --git a/pygmt/src/plot.py b/pygmt/src/plot.py index b3fd5f85625..aaf118b6b8a 100644 --- a/pygmt/src/plot.py +++ b/pygmt/src/plot.py @@ -168,8 +168,9 @@ def plot(self, data=None, x=None, y=None, size=None, direction=None, **kwargs): :gmt-docs:`plot.html#l`. no_clip : bool or str [**c**\|\ **r**]. - Do NOT clip symbols that fall outside map border [Default plots - points whose coordinates are strictly inside the map border only]. + Do **not** clip symbols that fall outside the frame boundaries + [Default plots points whose coordinates are strictly inside the + frame boundaries only]. The parameter does not apply to lines and polygons which are always clipped to the map region. For periodic (360-longitude) maps we must plot all symbols twice in case they are clipped by the diff --git a/pygmt/src/plot3d.py b/pygmt/src/plot3d.py index 622084169b3..ca937ce2a15 100644 --- a/pygmt/src/plot3d.py +++ b/pygmt/src/plot3d.py @@ -86,7 +86,7 @@ def plot3d( z, fill, and size, respectively. x/y/z : float or 1-D arrays The x, y, and z coordinates, or arrays of x, y and z coordinates of - the data points + the data points. size : 1-D array The size of the data points in units specified in ``style``. Only valid if using ``x``/``y``/``z``. @@ -135,10 +135,11 @@ def plot3d( :gmt-docs:`plot3d.html#l`. no_clip : bool or str [**c**\|\ **r**]. - Do NOT clip symbols that fall outside map border [Default plots - points whose coordinates are strictly inside the map border only]. + Do **not** clip symbols that fall outside the frame boundaries + [Default plots points whose coordinates are strictly inside the + frame boundaries only]. This parameter does not apply to lines and polygons which are always - clipped to the map region. For periodic (360-longitude) maps we + clipped to the map region. For periodic (360° longitude) maps we must plot all symbols twice in case they are clipped by the repeating boundary. ``no_clip=True`` will turn off clipping and not plot repeating symbols. Use ``no_clip="r"`` to turn off clipping diff --git a/pygmt/src/rose.py b/pygmt/src/rose.py index bd3c89aa9b5..b193eb2f4d2 100644 --- a/pygmt/src/rose.py +++ b/pygmt/src/rose.py @@ -75,10 +75,10 @@ def rose(self, data=None, length=None, azimuth=None, **kwargs): length/azimuth : float or 1-D arrays Length and azimuth values, or arrays of length and azimuth - values + values. orientation : bool - Specifies that the input data are orientation data (i.e., have a + Specify that the input data are orientation data (i.e., have a 180 degree ambiguity) instead of true 0-360 degree directions [Default is 0-360 degrees]. We compensate by counting each record twice: First as azimuth and second as azimuth +180. Ignored if @@ -87,17 +87,17 @@ def rose(self, data=None, length=None, azimuth=None, **kwargs): region : str or list *r0/r1/az0/az1* or [*r0*, *r1*, *az0*, *az1*]. *Required if this is the first plot command*. - Specifies the ``region`` of interest in (*r*, *azimuth*) space. + Specify the ``region`` of interest in (*r*, *azimuth*) space. Here, *r0* is 0 and *r1* is the maximal length in units. For *az0* and *az1*, specify either (-90, 90) or (0, 180) for half circle plot or (0, 360) for full circle. diameter : str - Sets the diameter of the rose diagram. If not given, + Set the diameter of the rose diagram. If not given, then we default to a diameter of 7.5 cm. sector : float or str - Gives the sector width in degrees for sector and rose diagram. + Give the sector width in degrees for sector and rose diagram. Default ``0`` means windrose diagram. Append **+r** to draw rose diagram instead of sector diagram (e.g. ``"10+r"``). @@ -175,7 +175,7 @@ def rose(self, data=None, length=None, azimuth=None, **kwargs): individual directions using the supplied attributes. alpha : float or str - Sets the confidence level used to determine if the mean + Set the confidence level used to determine if the mean resultant is significant (i.e., Lord Rayleigh test for uniformity) [Default is ``alpha=0.05``]. **Note**: The critical values are approximated [Berens, 2009] and requires diff --git a/pygmt/src/select.py b/pygmt/src/select.py index 46605c74542..ef07387cd68 100644 --- a/pygmt/src/select.py +++ b/pygmt/src/select.py @@ -84,7 +84,7 @@ def select(data=None, outfile=None, **kwargs): *gridmask*. Nodes that are outside are either NaN or zero. reverse : str [**cflrsz**]. - Reverses the sense of the test for each of the criteria specified: + Reverse the sense of the test for each of the criteria specified: - **c** select records NOT inside any point's circle of influence. - **f** select records NOT inside any of the polygons. diff --git a/pygmt/src/text.py b/pygmt/src/text.py index 1266204ef65..d7eec43b7fd 100644 --- a/pygmt/src/text.py +++ b/pygmt/src/text.py @@ -80,7 +80,7 @@ def text_( The x and y coordinates, or an array of x and y coordinates to plot the text. position : str - Sets reference point on the map for the text by using x, y + Set reference point on the map for the text by using x, y coordinates extracted from ``region`` instead of providing them through ``x``/``y``. Specify with a two-letter (order independent) code, chosen from: @@ -133,7 +133,7 @@ def text_( Set color for filling text boxes [Default is no fill]. offset : str [**j**\|\ **J**]\ *dx*\[/*dy*][**+v**\[*pen*]]. - Offsets the text from the projected (x, y) point by *dx*/\ *dy* + Offset the text from the projected (x, y) point by *dx*/\ *dy* [Default is ``"0/0"``]. If *dy* is not specified then it is set equal to *dx*. Use **j** to offset the text away from the point instead (i.e., the text @@ -143,10 +143,11 @@ def text_( point to the shifted point; append a pen to change the attributes for this line. pen : str - Sets the pen used to draw a rectangle around the text string + Set the pen used to draw a rectangle around the text string (see ``clearance``) [Default is ``"0.25p,black,solid"``]. no_clip : bool - Do NOT clip text at map boundaries [Default is with clip]. + Do **not** clip text at the frame boundaries [Default is + ``False``]. {verbose} {aspatial} {panel} diff --git a/pygmt/src/triangulate.py b/pygmt/src/triangulate.py index 4940071bef6..4fb1351e80e 100644 --- a/pygmt/src/triangulate.py +++ b/pygmt/src/triangulate.py @@ -100,7 +100,7 @@ def _triangulate( The name of the output ASCII file to store the results of the histogram equalization in. output_type: str - Determines the output type. Use "file", "xarray", "pandas", or + Determine the output type. Use "file", "xarray", "pandas", or "numpy". {verbose} {binary} diff --git a/pygmt/src/velo.py b/pygmt/src/velo.py index a1be115d126..e5e6bd681d1 100644 --- a/pygmt/src/velo.py +++ b/pygmt/src/velo.py @@ -71,7 +71,7 @@ def velo(self, data=None, **kwargs): :class:`pandas.DataFrame` inputs. spec: str - Selects the meaning of the columns in the data file and the figure to + Select the meaning of the columns in the data file and the figure to be plotted. In all cases, the scales are in data units per length unit and sizes are in length units (default length unit is controlled by :gmt-term:`PROJ_LENGTH_UNIT` unless **c**, **i**, or **p** is @@ -171,7 +171,7 @@ def velo(self, data=None, **kwargs): {frame} {cmap} rescale : str - can be used to rescale the uncertainties of velocities (``spec="e"`` + Can be used to rescale the uncertainties of velocities (``spec="e"`` and ``spec="r"``) and rotations (``spec="w"``). Can be combined with the ``confidence`` variable. uncertaintyfill : str @@ -212,9 +212,10 @@ def velo(self, data=None, **kwargs): ``cmap``). If instead modifier **+cf** is appended then the color from the cpt file is applied to error fill only [Default]. Use just **+c** to set both pen and fill color. - no_clip: bool or str - Do NOT skip symbols that fall outside the frame boundary specified - by ``region`` [Default plots symbols inside frame only]. + no_clip: bool + Do **not** skip symbols that fall outside the frame boundaries + [Default is ``False``, i.e., plot symbols inside the frame + boundaries only]. {verbose} pen : str [*pen*][**+c**\ [**f**\|\ **l**]]. diff --git a/pygmt/src/wiggle.py b/pygmt/src/wiggle.py index 2913c1d954b..e1e72aeafe4 100644 --- a/pygmt/src/wiggle.py +++ b/pygmt/src/wiggle.py @@ -66,7 +66,7 @@ def wiggle( {projection} {region} scale : str or float - Gives anomaly scale in data-units/distance-unit. Append **c**, **i**, + Give anomaly scale in data-units/distance-unit. Append **c**, **i**, or **p** to indicate the distance unit (centimeters, inches, or points); if no unit is given we use the default unit that is controlled by :gmt-term:`PROJ_LENGTH_UNIT`. @@ -75,7 +75,7 @@ def wiggle( [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ **+w**\ *length*\ [**+j**\ *justify*]\ [**+al**\|\ **r**]\ [**+o**\ *dx*\ [/*dy*]][**+l**\ [*label*]]. - Defines the reference point on the map for the vertical scale bar. + Define the reference point on the map for the vertical scale bar. fillpositive : str Set color or pattern for filling positive wiggles [Default is no fill]. diff --git a/pygmt/src/x2sys_init.py b/pygmt/src/x2sys_init.py index 020fa27823f..d5894174aa3 100644 --- a/pygmt/src/x2sys_init.py +++ b/pygmt/src/x2sys_init.py @@ -60,15 +60,15 @@ def x2sys_init(tag, **kwargs): - **geoz** (same, with one z-column). suffix : str - Specifies the file extension (suffix) for these data files. If not + Specify the file extension (suffix) for these data files. If not given we use the format definition file prefix as the suffix (see ``fmtfile``). discontinuity : str **d**\|\ **g**. - Selects geographical coordinates. Append **d** for discontinuity at the - Dateline (makes longitude go from -180 to +180) or **g** for - discontinuity at Greenwich (makes longitude go from 0 to 360 + Select geographical coordinates. Append **d** for discontinuity at the + Dateline (makes longitude go from -180° to +180°) or **g** for + discontinuity at Greenwich (makes longitude go from 0° to 360° [Default]). If not given we assume the data are Cartesian. spacing : str or list @@ -80,7 +80,7 @@ def x2sys_init(tag, **kwargs): units : str or list **d**\|\ **s**\ *unit*. - Sets the units used for distance and speed when requested by other + Set the units used for distance and speed when requested by other programs. Append **d** for distance or **s** for speed, then give the desired *unit* as: