Skip to content

v.profile.points

Creates a profile (transect) from points

v.profile.points [-z] [line_input=name] [coordinates=east,north [,east,north,...]] [point_input=name] [file_input=name] output=name [width=float] [--overwrite] [--verbose] [--quiet] [--qq] [--ui]

Example:

v.profile.points line_input=name output=name

grass.script.run_command("v.profile.points", line_input=None, coordinates=None, point_input=None, file_input=None, output, width=None, flags=None, overwrite=False, verbose=False, quiet=False, superquiet=False)

Example:

gs.run_command("v.profile.points", line_input="name", output="name")

Parameters

line_input=name
    Vector map with a single line (with 2 points)
    Vector line prepared ahead
coordinates=east,north [,east,north,...]
    Line coordinates (x,y,x,y)
    Two pairs of coordinates as an alternative to a vector line
point_input=name
    Vector map with points
    Or data source for direct OGR access
file_input=name
    LAS (or LAZ) file with a point cloud
    File to be imported using v.in.lidar
output=name [required]
    Name for output vector map
width=float
    Width of profile in map units
    Default with is 5% of the profile length
-z
    Start the z coordinates at 0 instead of the actual height
--overwrite
    Allow output files to overwrite existing files
--help
    Print usage summary
--verbose
    Verbose module output
--quiet
    Quiet module output
--qq
    Very quiet module output
--ui
    Force launching GUI dialog

line_input : str, optional
    Vector map with a single line (with 2 points)
    Vector line prepared ahead
    Used as: input, vector, name
coordinates : list[tuple[float, float]] | tuple[float, float] | list[float] | str, optional
    Line coordinates (x,y,x,y)
    Two pairs of coordinates as an alternative to a vector line
    Used as: input, coords, east,north
point_input : str, optional
    Vector map with points
    Or data source for direct OGR access
    Used as: input, vector, name
file_input : str, optional
    LAS (or LAZ) file with a point cloud
    File to be imported using v.in.lidar
    Used as: input, file, name
output : str, required
    Name for output vector map
    Used as: output, vector, name
width : float, optional
    Width of profile in map units
    Default with is 5% of the profile length
flags : str, optional
    Allowed values: z
    z
        Start the z coordinates at 0 instead of the actual height
overwrite: bool, optional
    Allow output files to overwrite existing files
    Default: False
verbose: bool, optional
    Verbose module output
    Default: False
quiet: bool, optional
    Quiet module output
    Default: False
superquiet: bool, optional
    Very quiet module output
    Default: False

DESCRIPTION

v.profile.points creates profile (transect) from vector point map or a lidar point cloud stored in a LAS file.

image-alt
Figure: Profile (transect) of a lidar point cloud, closer points are darker, further points are lighter

Workflow in GUI

First Map Display should contain some base layers such as point density raster or digital elevation model. First Map Display should contain the resulting profile or profiles. Optionally a grid overlay can be added. The "Zoom to selected map layers" button in the Map Display toolbar should be used to zoom to the newly created profile. The coordinates option in the Line tab can be activated, deactivated, or cleared during the work as need.

image-alt
Figure: Creating the profile in GUI: running module from the top left window; selecting line points in the Map Display in the top right; resulting profile in the bottom.

NOTES

ASCII files such as CSV can be profiled after import and raster maps can be profiles after conversion to vector points. It is advantageous to limit the import or the conversion just to the area of interest to avoid unnecessary overhead.

EXAMPLE

v.profile.points input_file=.../points.las output=points_profile width=5 \
    coord=2090904,731231,2091435,731252

AUTHOR

Vaclav Petras, NCSU GeoForAll Lab

SOURCE CODE

Available at: v.profile.points source code (history)
Latest change: Thursday Feb 20 13:02:26 2025 in commit 53de819