r.transect(1grass)

πŸŽ€ r.transect β€” the manual page, bestie edition πŸŽ€

okay so you found yourself at r.transect(1grass) in the GRASS User's Manual and honestly? slay. pull up a chair. this is the tool that goes pew pew along a line and reads out what the raster has to say about it. it's giving ✨transect✨ and it's giving ✨iconic✨. lowkey the whole thing fits in one breath, so let's go.


πŸ“› NAME πŸ“›

r.transect β€” outputs raster map layer values lying along user defined transect line(s). πŸ’–

πŸ”‘ KEYWORDS πŸ”‘

raster, profile, transect


πŸ“œ SYNOPSIS πŸ“œ

r.transect
r.transect --help
r.transect [-g] map=name
line=east,north,azimuth,distance[,east,north,azimuth,distance,...]
[null_value=string]   [--help]  [--verbose]  [--quiet]  [--ui]

🚩 Flags 🚩

  • -g β€” outputs easting and northing in the first two columns of a four column output. coordinate girlies rise up πŸ’…
  • --help β€” prints the usage summary. the classic "what does this even do" button.
  • --verbose β€” verbose module output. it will tell you everything, no cap.
  • --quiet β€” quiet module output. shhh. 🀫
  • --ui β€” forces launching the GUI dialog. for when clicking > typing, and that's valid.

🧸 Parameters 🧸

  • map=name [required] β€” raster map to be queried. bestie, you GOTTA name the map, it's required fr fr.
  • line=east,north,azimuth,distance[,east,north,azimuth,distance,...] [required] β€” the transect definition. also required. also not optional. also did I mention required.
  • null_value=string β€” string representing NULL value. Default: *

🌸 DESCRIPTION 🌸

r.transect outputs, in ASCII, the values in a raster map which lie along one or more user-defined transect lines. the transects are described by their starting coordinates, azimuth, and distance. no drama, just a lil line drawn across your map and a lil list of numbers coming back. πŸ¦‹

the line parameter is a definition of (each) transect line, specified by the geographic coordinates of its starting point (easting, northing), the angle and direction of its travel (azimuth), and its distance. so that's four lil numbers per line and they're a whole squad. πŸ‘‘

the azimuth is an angle, in degrees, measured to the east of north. the distance is in map units (meters for a metered database, like UTM). so like, north is the reference, east is where you start counting to, and the distance is just… however long you're walking. πŸšΆβ™€οΈβœ¨

the null parameter can optionally be set to change the character string representing null values. yes, you can pick your own little placeholder glyph. customise your void. πŸ’œ


πŸ“ NOTES πŸ“

this program is a front-end to the r.profile program. it simply converts the azimuth and distance to an ending coordinate and then runs r.profile.

so it's not doing the heavy lifting itself, it's delegating. respect. 🫢

also, there once were width= and result=raw|median|average options which are not currently implemented. so if you see them in the wild, they're ghosts. πŸ’€ don't come for me, I don't make the rules.


πŸ‘€ SEE ALSO πŸ‘€

  • r.profile
  • wxGUI profile tool

πŸ‘‘ AUTHOR πŸ‘‘

Michael Shapiro, U.S. Army Construction Engineering Research Laboratory


πŸ’Ύ SOURCE CODE πŸ’Ύ

Available at: r.transect source code (history)

Latest change: Thursday May 08 20:58:05 2025 in commit: 4144ba81fa125e1549fc52e1cf5feb4fa004be8b

Main index | Raster index | Topics index | Keywords index | Graphical index | Full index


and that's the whole page, bestie πŸ’– we were hanging out in the GRASS 8.5.0 Reference Manual the entire time β€” Β© 2003-2026 GRASS Development Team, GRASS 8.5.0 Reference Manual β€” and this lil icon of a manpage is r.transect(1grass), GRASS 8.5.0. periodt. βœ¨πŸŽ€πŸŒΈ

πŸ“¦ where this page comes from