qgis_creategrid: QGIS algorithm - Create grid

View source: R/qgis_creategrid.R

qgis_creategridR Documentation

QGIS algorithm - Create grid

Description

QGIS Algorithm provided by QGIS (native c++) Create grid (native:creategrid). This algorithm creates a vector layer with a grid covering a given extent. Elements in the grid can be points, lines or polygons. The size and/or placement of each element in the grid is defined using a horizontal and vertical spacing. The CRS of the output layer must be defined. The grid extent and the spacing values must be expressed in the coordinates and units of this CRS. The top-left point (minX, maxY) is used as the reference point. That means that, at that point, an element is guaranteed to be placed. Unless the width and height of the selected extent is a multiple of the selected spacing, that is not true for the other points that define that extent.

Usage

qgis_creategrid(
  TYPE = qgisprocess:::qgis_default_value(),
  EXTENT = qgisprocess:::qgis_default_value(),
  HSPACING = qgisprocess:::qgis_default_value(),
  VSPACING = qgisprocess:::qgis_default_value(),
  HOVERLAY = qgisprocess:::qgis_default_value(),
  VOVERLAY = qgisprocess:::qgis_default_value(),
  CRS = qgisprocess:::qgis_default_value(),
  OUTPUT = qgisprocess:::qgis_default_value(),
  ...,
  .complete_output = .complete_output_option(),
  .quiet = .quiet_option(),
  .messages = .message_option()
)

Arguments

TYPE

enum of ⁠("Point", "Line", "Rectangle (Polygon)", "Diamond (Polygon)", "Hexagon (Polygon)")⁠ - Grid type. Number of selected option, e.g. '1'. Comma separated list of options, e.g. '1,3'.

EXTENT

extent - Grid extent. A comma delimited string of x min, x max, y min, y max. E.g. '4,10,101,105'. Path to a layer. The extent of the layer is used..

HSPACING

distance - Horizontal spacing. A numeric value. field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field. expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression.

VSPACING

distance - Vertical spacing. A numeric value. field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field. expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression.

HOVERLAY

distance - Horizontal overlay. A numeric value. field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field. expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression.

VOVERLAY

distance - Vertical overlay. A numeric value. field:FIELD_NAME to use a data defined value taken from the FIELD_NAME field. expression:SOME EXPRESSION to use a data defined value calculated using a custom QGIS expression.

CRS

crs - Grid CRS. CRS as an auth ID (e.g. 'EPSG:3111'). CRS as a PROJ4 string (e.g. 'PROJ4:…'). CRS as a WKT string (e.g. 'WKT:…'). Path to a layer. The CRS of the layer is used..

OUTPUT

sink - Grid. Path for new vector layer.

...

further parameters passed to qgisprocess::qgis_run_algorithm()

.complete_output

logical specifying if complete out of qgisprocess::qgis_run_algorithm() should be used (TRUE) or first output (most likely the main) should read (FALSE). Default value is TRUE.

.quiet

logical specifying if parameter .quiet for qgisprocess::qgis_run_algorithm() Default value is TRUE.

.messages

logical specifying if messages from qgisprocess::qgis_run_algorithm() should be printed (TRUE) or not (FALSE). Default value is FALSE.

Details

Outputs description

  • OUTPUT - outputVector - Grid


JanCaha/r_package_qgis documentation built on April 4, 2024, 8:10 p.m.