1d.vect(1) Grass User's Manual d.vect(1)
2
3
4
6 d.vect - Displays user-specified vector map in the active graphics
7 frame.
8
10 display, graphics, vector, level1
11
13 d.vect
14 d.vect --help
15 d.vect [-cirs] map=name [layer=string] display=string[,string,...]
16 [type=string[,string,...]] [cats=range] [where=sql_query]
17 [color=name] [fill_color=name] [rgb_column=name] [zcolor=style]
18 [width=integer] [width_column=name] [width_scale=float]
19 [icon=string] [size=float] [size_column=name] [rotation_col‐
20 umn=name] [icon_area=string] [icon_line=string] [leg‐
21 end_label=string] [label_layer=string] [attribute_column=name]
22 [label_color=name] [label_bgcolor=name] [label_bcolor=name]
23 [label_size=integer] [font=string] [encoding=string]
24 [xref=string] [yref=string] [minreg=float] [maxreg=float]
25 [--help] [--verbose] [--quiet] [--ui]
26
27 Flags:
28 -c
29 Random colors according to category number (or layer number if
30 ’layer=-1’ is given)
31
32 -i
33 Use values from ’cats’ option as feature id
34
35 -r
36 Use square root of the value of size_column
37 This makes circle areas proportionate to the size_column values
38 instead of circle radius
39
40 -s
41 Do not show this layer in vector legend
42
43 --help
44 Print usage summary
45
46 --verbose
47 Verbose module output
48
49 --quiet
50 Quiet module output
51
52 --ui
53 Force launching GUI dialog
54
55 Parameters:
56 map=name [required]
57 Name of vector map
58 Or data source for direct OGR access
59
60 layer=string
61 Layer number or name (’-1’ for all layers)
62 A single vector map can be connected to multiple database tables.
63 This number determines which table to use. When used with direct
64 OGR access this is the layer name.
65 Default: 1
66
67 display=string[,string,...] [required]
68 Display
69 Options: shape, cat, topo, vert, dir, zcoor
70 Default: shape
71 shape: Display geometry of features
72 cat: Display category numbers of features
73 topo: Display topology information (nodes, edges)
74 vert: Display vertices of features
75 dir: Display direction of linear features
76 zcoor: Display z-coordinate of features (only for 3D vector maps)
77
78 type=string[,string,...]
79 Input feature type
80 Options: point, line, boundary, centroid, area, face
81 Default: point,line,area,face
82
83 cats=range
84 Category values
85 Example: 1,3,7-9,13
86
87 where=sql_query
88 WHERE conditions of SQL statement without ’where’ keyword
89 Example: income < 1000 and population >= 10000
90
91 color=name
92 Feature color
93 Either a standard color name, R:G:B triplet, or "none"
94 Default: black
95
96 fill_color=name
97 Area fill color
98 Either a standard color name, R:G:B triplet, or "none"
99 Default: 200:200:200
100
101 rgb_column=name
102 Colorize features according to color definition column
103 Color definition in R:G:B form
104
105 zcolor=style
106 Colorize point or area features according to z-coordinate
107 Options: aspect, aspectcolr, bcyr, bgyr, blues, byg, byr, celsius,
108 corine, curvature, differences, elevation, etopo2, evi, fahrenheit,
109 gdd, grass, greens, grey, grey.eq, grey.log, grey1.0, grey255, gyr,
110 haxby, kelvin, ndvi, ndwi, oranges, population, population_dens,
111 precipitation, precipitation_daily, precipitation_monthly, rainbow,
112 ramp, random, reds, roygbiv, rstcurv, ryb, ryg, sepia, slope, soil‐
113 moisture, srtm, srtm_plus, terrain, viridis, water, wave
114 aspect: aspect oriented grey colors
115 aspectcolr: aspect oriented rainbow colors
116 bcyr: blue through cyan through yellow to red
117 bgyr: blue through green through yellow to red
118 blues: white to blue
119 byg: blue through yellow to green
120 byr: blue through yellow to red
121 celsius: blue to red for degree Celsius temperature
122 corine: EU Corine land cover colors
123 curvature: for terrain curvatures (from v.surf.rst and
124 r.slope.aspect)
125 differences: differences oriented colors
126 elevation: maps relative ranges of raster values to elevation
127 color ramp
128 etopo2: colors for ETOPO2 worldwide bathymetry/topography
129 evi: enhanced vegetative index colors
130 fahrenheit: blue to red for Fahrenheit temperature
131 gdd: accumulated growing degree days
132 grass: GRASS GIS green (perceptually uniform)
133 greens: white to green
134 grey: grey scale
135 grey.eq: histogram-equalized grey scale
136 grey.log: histogram logarithmic transformed grey scale
137 grey1.0: grey scale for raster values between 0.0-1.0
138 grey255: grey scale for raster values between 0-255
139 gyr: green through yellow to red
140 haxby: relative colors for bathymetry or topography
141 kelvin: blue to red for temperature in Kelvin scale
142 ndvi: Normalized Difference Vegetation Index colors
143 ndwi: Normalized Difference Water Index colors
144 oranges: white to orange
145 population: color table covering human population classification
146 breaks
147 population_dens: color table covering human population density
148 classification breaks
149 precipitation: precipitation color table (0..2000mm)
150 precipitation_daily: precipitation color table (0..1000mm)
151 precipitation_monthly: precipitation color table (0..1000mm)
152 rainbow: rainbow color table
153 ramp: color ramp
154 random: random color table
155 reds: white to red
156 roygbiv: no description
157 rstcurv: terrain curvature (from r.resamp.rst)
158 ryb: red through yellow to blue
159 ryg: red through yellow to green
160 sepia: yellowish-brown through to white
161 slope: r.slope.aspect-type slope colors for raster values 0-90
162 soilmoisture: soilmoisture color table (0.0-1.0)
163 srtm: color palette for Shuttle Radar Topography Mission elevation
164 srtm_plus: color palette for Shuttle Radar Topography Mission ele‐
165 vation (with seafloor colors)
166 terrain: global elevation color table covering -11000 to +8850m
167 viridis: perceptually uniform sequential color table viridis
168 water: water depth
169 wave: color wave
170
171 width=integer
172 Line width
173 Default: 0
174
175 width_column=name
176 Name of numeric column containing line width
177 These values will be scaled by width_scale
178
179 width_scale=float
180 Scale factor for width_column
181 Default: 1
182
183 icon=string
184 Point and centroid symbol
185 Options: basic/arrow, basic/arrow1, basic/arrow2, basic/arrow3,
186 basic/box, basic/circle, basic/cross1, basic/cross2, basic/cross3,
187 basic/diamond, basic/hexagon, basic/marker, basic/octagon,
188 basic/pin, basic/pin_dot, basic/point, basic/pushpin, basic/star,
189 basic/triangle, basic/x, demo/muchomurka, demo/smrk,
190 extra/4pt_star, extra/adcp, extra/airport, extra/alpha_flag,
191 extra/bridge, extra/dim_arrow, extra/dive_flag, extra/fiducial,
192 extra/fish, extra/half-box, extra/half-circle, extra/offbox_ne,
193 extra/offbox_nw, extra/offbox_se, extra/offbox_sw, extra/pentagon,
194 extra/ping, extra/ring, extra/simple_zia, extra/target, geol‐
195 ogy/circle_cross, geology/half-arrow_left, geol‐
196 ogy/half-arrow_right, geology/strike_box, geology/strike_circle,
197 geology/strike_cleavage, geology/strike_half-bowtie, geol‐
198 ogy/strike_line, geology/strike_parallel, geology/strike_triangle,
199 legend/area, legend/area_curved, legend/line, legend/line_crooked,
200 n_arrows/basic_compass, n_arrows/fancy_compass, n_arrows/n_arrow1a,
201 n_arrows/n_arrow1b, n_arrows/n_arrow2, n_arrows/n_arrow3,
202 n_arrows/n_arrow4, n_arrows/n_arrow5, n_arrows/n_arrow6,
203 n_arrows/n_arrow7a, n_arrows/n_arrow7b, n_arrows/n_arrow8a,
204 n_arrows/n_arrow8b, n_arrows/n_arrow9
205 Default: basic/x
206
207 size=float
208 Symbol size
209 When used with the size_column option this becomes the scale factor
210 Default: 5
211
212 size_column=name
213 Name of numeric column containing symbol size
214
215 rotation_column=name
216 Name of numeric column containing symbol rotation angle
217 Measured in degrees CCW from east
218
219 icon_area=string
220 Area/boundary symbol for legend
221 Options: basic/arrow, basic/arrow1, basic/arrow2, basic/arrow3,
222 basic/box, basic/circle, basic/cross1, basic/cross2, basic/cross3,
223 basic/diamond, basic/hexagon, basic/marker, basic/octagon,
224 basic/pin, basic/pin_dot, basic/point, basic/pushpin, basic/star,
225 basic/triangle, basic/x, demo/muchomurka, demo/smrk,
226 extra/4pt_star, extra/adcp, extra/airport, extra/alpha_flag,
227 extra/bridge, extra/dim_arrow, extra/dive_flag, extra/fiducial,
228 extra/fish, extra/half-box, extra/half-circle, extra/offbox_ne,
229 extra/offbox_nw, extra/offbox_se, extra/offbox_sw, extra/pentagon,
230 extra/ping, extra/ring, extra/simple_zia, extra/target, geol‐
231 ogy/circle_cross, geology/half-arrow_left, geol‐
232 ogy/half-arrow_right, geology/strike_box, geology/strike_circle,
233 geology/strike_cleavage, geology/strike_half-bowtie, geol‐
234 ogy/strike_line, geology/strike_parallel, geology/strike_triangle,
235 legend/area, legend/area_curved, legend/line, legend/line_crooked,
236 n_arrows/basic_compass, n_arrows/fancy_compass, n_arrows/n_arrow1a,
237 n_arrows/n_arrow1b, n_arrows/n_arrow2, n_arrows/n_arrow3,
238 n_arrows/n_arrow4, n_arrows/n_arrow5, n_arrows/n_arrow6,
239 n_arrows/n_arrow7a, n_arrows/n_arrow7b, n_arrows/n_arrow8a,
240 n_arrows/n_arrow8b, n_arrows/n_arrow9
241 Default: legend/area
242
243 icon_line=string
244 Line symbol for legend
245 Options: basic/arrow, basic/arrow1, basic/arrow2, basic/arrow3,
246 basic/box, basic/circle, basic/cross1, basic/cross2, basic/cross3,
247 basic/diamond, basic/hexagon, basic/marker, basic/octagon,
248 basic/pin, basic/pin_dot, basic/point, basic/pushpin, basic/star,
249 basic/triangle, basic/x, demo/muchomurka, demo/smrk,
250 extra/4pt_star, extra/adcp, extra/airport, extra/alpha_flag,
251 extra/bridge, extra/dim_arrow, extra/dive_flag, extra/fiducial,
252 extra/fish, extra/half-box, extra/half-circle, extra/offbox_ne,
253 extra/offbox_nw, extra/offbox_se, extra/offbox_sw, extra/pentagon,
254 extra/ping, extra/ring, extra/simple_zia, extra/target, geol‐
255 ogy/circle_cross, geology/half-arrow_left, geol‐
256 ogy/half-arrow_right, geology/strike_box, geology/strike_circle,
257 geology/strike_cleavage, geology/strike_half-bowtie, geol‐
258 ogy/strike_line, geology/strike_parallel, geology/strike_triangle,
259 legend/area, legend/area_curved, legend/line, legend/line_crooked,
260 n_arrows/basic_compass, n_arrows/fancy_compass, n_arrows/n_arrow1a,
261 n_arrows/n_arrow1b, n_arrows/n_arrow2, n_arrows/n_arrow3,
262 n_arrows/n_arrow4, n_arrows/n_arrow5, n_arrows/n_arrow6,
263 n_arrows/n_arrow7a, n_arrows/n_arrow7b, n_arrows/n_arrow8a,
264 n_arrows/n_arrow8b, n_arrows/n_arrow9
265 Default: legend/line
266
267 legend_label=string
268 Label to display after symbol in vector legend
269
270 label_layer=string
271 Layer number for labels (default: the given layer number)
272 Vector features can have category values in different layers. This
273 number determines which layer to use. When used with direct OGR
274 access this is the layer name.
275 Default: 1
276
277 attribute_column=name
278 Name of column to be displayed as a label
279
280 label_color=name
281 Label color
282 Either a standard color name or R:G:B triplet
283 Default: red
284
285 label_bgcolor=name
286 Label background color
287 Either a standard color name, R:G:B triplet, or "none"
288 Default: none
289
290 label_bcolor=name
291 Label border color
292 Either a standard color name, R:G:B triplet, or "none"
293 Default: none
294
295 label_size=integer
296 Label size (pixels)
297 Default: 8
298
299 font=string
300 Font name
301
302 encoding=string
303 Text encoding
304
305 xref=string
306 Label horizontal justification
307 Options: left, center, right
308 Default: left
309
310 yref=string
311 Label vertical justification
312 Options: top, center, bottom
313 Default: center
314
315 minreg=float
316 Minimum region size (average from height and width) when map is
317 displayed
318
319 maxreg=float
320 Maximum region size (average from height and width) when map is
321 displayed
322
324 d.vect displays vector maps in the active frame on the graphics moni‐
325 tor.
326
328 d.vect can simply be used typing d.vect map=vector_map. There are a
329 large variety of optional parameters which allow the user to specify
330 vector type, colors, data fields, SQL queries, label size and justifi‐
331 cation, etc.
332
333 By default d.vect areas are filled with fill_color and outlined with
334 color. Area outlines can be suppressed with
335 d.vect map=vector_map color=none
336 and areas can be made transparent with
337 d.vect map=vector_map fill_color=none
338
339 In order to display attributes in the map, attribute_column must be
340 specified.
341
342 Feature colors may be specified by v.colors in a form of color table or
343 in an attribute table column containing RRR:GGG:BBB values.
344
345 A table for a vector map might look like this:
346 db.select sql="select * from testisola"
347 cat|label|GRASSRGB
348 0|no data|255:255:255
349 90|FRASSILONGO|23:245:67
350 104|LEVICO|23:145:67
351 139|PERGINE VALSUGANA|223:45:237
352 168|SANT’ORSOLA|223:45:67
353 190|TENNA|123:45:67
354
355 To add the GRASSRGB color column, use v.db.addcolumn:
356 v.db.addcolumn map=testisola columns="GRASSRGB varchar(11)"
357
358 To add/change a color, use v.db.update:
359 v.db.update map=testisola column=GRASSRGB value="123:45:237" where="cat=139"
360
361 A much simpler method of color coding is by using the -c flag which
362 displays vector elements of like category number with a random color.
363
364 This module can use FreeType/TrueType fonts if they have already been
365 selected with d.font.
366
367 Parameter width is set by default to ’0’. XDRIVER specifies the precise
368 behaviour for non-zero line width, but drivers have some freedom as to
369 how zero-width lines are handled, so they can use the hardware’s "thin
370 line" drawing primitive, if it has one. A width of zero can potentially
371 result in significantly faster operation. On drivers where there is no
372 such thing as a "thin" line, the driver will use a sensible default
373 (which might not be the same as ’1’).
374
376 Spearfish examples:
377 # display roads with category numbers:
378 d.vect map=roads display=shape,cat label_color=green
379 # display randomly colorized soils map with attributes
380 d.vect -c map=soils attribute_column=label
381 # display randomly colorized selected vectors from soils map
382 d.vect -c map=soils where="label=’VBF’" display=shape attribute_column=label
383
384 3D points, 3D lines and 3D polygons colorized according to z height
385 (for 3D lines and polygons a z height is defined by a first vertex):
386 g.region raster=elevation.10m
387 r.random input=elevation.10m n=5000 vector=random3d -d
388 d.mon start=x0
389 # display as black points
390 d.vect map=random3d
391 # display 3D points colorized according to z height
392 d.vect map=random3d zcolor=gyr
393 # 3D contour lines
394 r.contour input=elevation.10m output=contour20m step=20
395 d.vect map=contour20m zcolor=gyr
396 # generate 3D triangles
397 v.delaunay input=random3d output=random3d_del
398 # display 3D polygons colorized according to z height
399 d.vect map=random3d_del type=area zcolor=gyr
400
402 v.colors, d.erase, d.rast, v.colors, v.db.addcolumn, v.db.update
403
404 GRASS SQL interface
405
407 CERL
408 Radim Blazek, ITC-Irst, Trento, Italy
409 Support for color tables by Martin Landa, Czech Technical University in
410 Prague (8/2011)
411 and many other GRASS developers
412
413 Last changed: $Date: 2018-08-25 18:54:22 +0200 (Sat, 25 Aug 2018) $
414
416 Available at: d.vect source code (history)
417
418 Main index | Display index | Topics index | Keywords index | Graphical
419 index | Full index
420
421 © 2003-2019 GRASS Development Team, GRASS GIS 7.4.4 Reference Manual
422
423
424
425GRASS 7.4.4 d.vect(1)