r.support
Allows creation and/or modification of raster map layer support files.
r.support [-bsnd] map=name [title=phrase] [history=phrase] [units=string] [vdatum=string] [source1=phrase] [source2=phrase] [description=phrase] [raster=string] [loadhistory=name] [savehistory=name] [semantic_label=phrase] [--overwrite] [--verbose] [--quiet] [--qq] [--ui]
Example:
r.support map=name
grass.script.run_command("r.support", map, title=None, history=None, units=None, vdatum=None, source1=None, source2=None, description=None, raster=None, loadhistory=None, savehistory=None, semantic_label=None, flags=None, overwrite=False, verbose=False, quiet=False, superquiet=False)
Example:
gs.run_command("r.support", map="name")
Parameters
map=name [required]
Name of raster map
title=phrase
Title for resultant raster map
history=phrase
Text to append to the next line of the map's metadata file
units=string
Text to use for map data units
vdatum=string
Text to use for map vertical datum
source1=phrase
Text to use for data source, line 1
source2=phrase
Text to use for data source, line 2
description=phrase
Text to use for data description or keyword(s)
raster=string
Raster map from which to copy category table
loadhistory=name
Text file from which to load history
savehistory=name
Text file in which to save history
semantic_label=phrase
Semantic label e.g. S2_8A
-b
Delete the semantic label
-s
Update statistics (histogram, range)
-n
Create/reset the null file
-d
Delete the null file
--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
map : str, required
Name of raster map
Used as: input, raster, name
title : str, optional
Title for resultant raster map
Used as: phrase
history : str, optional
Text to append to the next line of the map's metadata file
Used as: phrase
units : str, optional
Text to use for map data units
vdatum : str, optional
Text to use for map vertical datum
source1 : str, optional
Text to use for data source, line 1
Used as: phrase
source2 : str, optional
Text to use for data source, line 2
Used as: phrase
description : str, optional
Text to use for data description or keyword(s)
Used as: phrase
raster : str, optional
Raster map from which to copy category table
Used as: input, raster
loadhistory : str, optional
Text file from which to load history
Used as: input, file, name
savehistory : str, optional
Text file in which to save history
Used as: output, file, name
semantic_label : str, optional
Semantic label e.g. S2_8A
Used as: phrase
flags : str, optional
Allowed values: b, s, n, d
b
Delete the semantic label
s
Update statistics (histogram, range)
n
Create/reset the null file
d
Delete the null file
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
r.support allows the user to create and/or edit raster map support information. Editing of raster map color tables, category labels, header, history, semantic label elements and title is supported. Category labels can also be copied from another raster map.
Raster semantic labels and band management
Raster semantic label concept is similar to dimension name in other GIS and remote sensing applications. Most common usage will be assigning a remote sensing platform sensor band identifier to the raster map metadata, although any identifier is supported (see i.band.library). Raster semantic label is suggested to work with imagery classification tools.
EXAMPLES
These examples are based on the North Carolina dataset, more specifically the landuse raster map. Copy the landuse map to the current mapset
g.copy raster=landuse,my_landuse
Update statistics
r.support -s map=my_landuse
Update Title
r.support map=my_landuse title="Landuse copied"
Append to History Metadata
r.support map=my_landuse history="Copied from PERMANENT mapset"
Update Units Display
r.support map=my_landuse units=meter
Set semantic label
Note: landuse map doesn't confirm to CORINE specification. This is an example only.
r.support map=my_landuse semantic_label=CORINE_LULC
NOTES
If metadata options such as title or history are given the module will run non-interactively. If only the map name is given r.support will run interactively within a terminal shell and the user with be prompted for input.
Freeform metadata information is stored in a "hist
" file which may be
appended to by using the history option. Currently this is limited
to 50 lines of text with a maximum line length of 78 characters. Any
input larger than this will be wrapped to the next line. All other
metadata strings available as standard options are limited to 79
characters.
SEE ALSO
i.band.library, r.category, r.describe, r.info, r.null, r.region, r.report, r.semantic.label, r.timestamp
AUTHORS
Micharl Shapiro, CERL: Original author
Brad Douglas: GRASS 6 Port
M. Hamish Bowman: command line enhancements
Markus Neteler: category copy from other map
Maris Nartiss: semantic label management
SOURCE CODE
Available at: r.support source code
(history)
Latest change: Friday Feb 07 19:16:09 2025 in commit a82a39f