1PSROSE(1) GMT PSROSE(1)
2
3
4
6 psrose - Plot a polar histogram (rose, sector, windrose diagrams)
7
9 psrose [ table ] [ -A[r]sector_width ] [ -B[p|s]parameters ] [
10 -Cm|[+w]mode_file ] [ -D ] [ -F ] [ -Gfill ] [ -I ] [ -K ] [
11 -L[wlabel,elabel,slabel,nlabel] ] [ -Mparameters ] [ -O ] [ -P ] [
12 -Qalpha ] [ -Rr0/r1/az_0/az_1 ] [ -S[n]radial_scale ] [ -T ] [
13 -U[stamp] ] [ -V[level] ] [ -W[v]pen ] [ -Xx_offset ] [ -Yy_offset
14 ] [ -Zu|scale ] [ -bibinary ] [ -dinodata ] [ -eregexp ] [ -hheaders ]
15 [ -iflags ] [ -pflags ] [ -ttransp ] [ -:[i|o] ]
16
17 Note: No space is allowed between the option flag and the associated
18 arguments.
19
21 psrose reads (length,azimuth) pairs from file [or standard input] and
22 generates PostScript code that will plot a windrose diagram. Add -i0
23 if your file only has azimuth values. Optionally (with -A), polar his‐
24 tograms may be drawn (sector diagram or rose diagram). Options include
25 full circle and half circle plots. The PostScript code is written to
26 standard output. The outline of the windrose is drawn with the same
27 color as MAP_DEFAULT_PEN.
28
30 None.
31
33 table One or more ASCII (or binary, see -bi[ncols][type]) data table
34 file(s) holding a number of data columns. If no tables are given
35 then we read from standard input. If a file with only azimuths
36 are given, use -i to indicate the single column with azimuths;
37 then all lengths are set to unity (see -Zu to set actual lengths
38 to unity as well).
39
40 -A[r]sector_width
41 Gives the sector width in degrees for sector and rose diagram.
42 [Default 0 means windrose diagram]. Use -Ar to draw rose diagram
43 instead of sector diagram.
44
45 -B[p|s]parameters (more ...)
46 Set map boundary frame and axes attributes.
47
48 Remember that "x" here is
49 radial distance and "y" is azimuth. The ylabel may be used to plot a figure caption.
50 The scale bar length is determined by the radial gridline spacing.
51
52
53 -Cm|[+w]mode_file
54 Plot vectors showing the principal directions given in the
55 mode_file file. Alternatively, specify -Cm to compute and plot
56 mean direction. See -M to control the vector attributes.
57 Finally, to instead save the computed mean direction and other
58 statistics, use [m]+wmode_file. The eight items saved to a sin‐
59 gle record are: mean_az, mean_r, mean_resultant, max_r,
60 scaled_mean_r, length_sum, n, sign@alpha, where the last term is
61 0 or 1 depending on whether the mean resultant is significant at
62 the level of confidence set via -Q.
63
64 -D Shift sectors so that they are centered on the bin interval
65 (e.g., first sector is centered on 0 degrees).
66
67 -F Do not draw the scale length bar [Default plots scale in lower
68 right corner]
69
70 -Gfill Selects shade, color or pattern for filling the sectors [Default
71 is no fill]K.
72
73 -I Inquire. Computes statistics needed to specify a useful -R. No
74 plot is generated. The following statistics are written to std‐
75 out: n, mean az, mean r, mean resultant length, max bin sum,
76 scaled mean, and linear length sum.
77
78 -K (more ...)
79 Do not finalize the PostScript plot.
80
81 -L[wlabel,elabel,slabel,nlabel]
82 Specify labels for the 0, 90, 180, and 270 degree marks. For
83 full-circle plot the default is WEST,EAST,SOUTH,NORTH and for
84 half-circle the default is 90W,90E,-,0. A - in any entry dis‐
85 ables that label. Use -L with no argument to disable all four
86 labels. Note that the GMT_LANGUAGE setting will affect the
87 words used.
88
89 -Mparameters
90 Used with -C to modify vector parameters. For vector heads,
91 append vector head size [Default is 0, i.e., a line]. See VECTOR
92 ATTRIBUTES for specifying additional attributes. If -C is not
93 given and the current plot mode is to draw a windrose diagram
94 then using -M will add vector heads to all individual directions
95 using the supplied attributes.
96
97 -O (more ...)
98 Append to existing PostScript plot.
99
100 -P (more ...)
101 Select "Portrait" plot orientation.
102
103 -Qalpha ]
104 Sets the confidence level used to determine if the mean resul‐
105 tant is significant (i.e., Lord Rayleigh test for uniformity)
106 [0.05]. Note: The critical values are approximated [Berens,
107 2009] and requires at least 10 points; the critical resultants
108 are accurate to at least 3 significant digits. For smaller data
109 sets you should consult exact statistical tables.
110
111 -Rr0/r1/az_0/az_1
112 Specifies the 'region' of interest in (r,azimuth) space. r0 is
113 0, r1 is max length in units. For azimuth, specify either -90/90
114 or 0/180 for half circle plot or 0/360 for full circle.
115
116 -S[n]plot_radius
117 Specifies radius of plotted circle (append a unit from c|i|p).
118 Use -Sn to normalize input radii (or bin counts if -A is used)
119 by the largest value so all radii (or bin counts) range from 0
120 to 1.
121
122 -T Specifies that the input data are orientation data (i.e., have a
123 180 degree ambiguity) instead of true 0-360 degree directions
124 [Default]. We compensate by counting each record twice: First as
125 azimuth and second as azimuth + 180. Ignored if range is given
126 as -90/90 or 0/180.
127
128 -U[[just]/dx/dy/][c|label] (more ...)
129 Draw GMT time stamp logo on plot.
130
131 -V[level] (more ...)
132 Select verbosity level [c].
133
134 -Wpen Set pen attributes for sector outline or rose plot. [Default is
135 no outline]. Use -Wvpen to change pen used to draw vector
136 (requires -C) [Default is same as sector outline].
137
138 -X[a|c|f|r][x-shift[u]]
139
140 -Y[a|c|f|r][y-shift[u]] (more ...)
141 Shift plot origin.
142
143 -Zu|scale
144 Multiply the data radii by scale. E.g., use -Z0.001 to convert
145 your data from m to km. To exclude the radii from consideration,
146 set them all to unity with -Zu [Default is no scaling].
147
148 -: Input file has (azimuth,radius) pairs rather than the expected
149 (radius,azimuth).
150
151 -bi[ncols][t] (more ...)
152 Select native binary input. [Default is 2 input columns].
153
154 -dinodata (more ...)
155 Replace input columns that equal nodata with NaN.
156
157 -e[~]"pattern" | -e[~]/regexp/[i] (more ...)
158 Only accept data records that match the given pattern.
159
160 -h[i|o][n][+c][+d][+rremark][+rtitle] (more ...)
161 Skip or produce header record(s).
162
163 -icols[+l][+sscale][+ooffset][,...] (more ...)
164 Select input columns and transformations (0 is first column).
165
166 -p[x|y|z]azim[/elev[/zlevel]][+wlon0/lat0[/z0]][+vx0/y0] (more ...)
167 Select perspective view.
168
169 -t[transp] (more ...)
170 Set PDF transparency level in percent.
171
172 -^ or just -
173 Print a short message about the syntax of the command, then
174 exits (NOTE: on Windows just use -).
175
176 -+ or just +
177 Print an extensive usage (help) message, including the explana‐
178 tion of any module-specific option (but not the GMT common
179 options), then exits.
180
181 -? or no arguments
182 Print a complete usage (help) message, including the explanation
183 of all options, then exits.
184
186 Several modifiers may be appended to the vector-producing options to
187 specify the placement of vector heads, their shapes, and the justifica‐
188 tion of the vector. Below, left and right refers to the side of the
189 vector line when viewed from the start point to the end point of the
190 segment:
191 +aangle sets the angle of the vector head apex [30].
192
193 +b places a vector head at the beginning of the vector path [none].
194 Optionally, append t for a terminal line, c for a circle, a for
195 arrow [Default], i for tail, A for plain arrow, and I for plain
196 tail. Further append l|r to only draw the left or right side of
197 this head [both sides].
198
199 +e places a vector head at the end of the vector path [none].
200 Optionally, append t for a terminal line, c for a circle, a for
201 arrow [Default], i for tail, A for plain arrow, and I for plain
202 tail. Further append l|r to only draw the left or right side of
203 this head [both sides].
204
205 +g-|fill turns off vector head fill (if -) or sets the vector head
206 fill [Default fill is used, which may be no fill].
207
208 +hshape sets the shape of the vector head (range -2/2). Default is
209 controlled by MAP_VECTOR_SHAPE [0].
210
211 +l draws half-arrows, using only the left side of specified heads
212 [both sides].
213
214 +m places a vector head at the mid-point the vector path [none].
215 Append f or r for forward or reverse direction of the vector [for‐
216 ward]. Optionally, append t for a terminal line, c for a circle, or
217 a for arrow head [Default]. Further append l|r to only draw the
218 left or right side of this head [both sides]. Cannot be combined
219 with +b or +e.
220
221 +nnorm scales down vector attributes (pen thickness, head size) with
222 decreasing length, where vectors shorter than norm will have their
223 attributes scaled by length/norm [arrow attributes remains invariant
224 to length].
225
226 +oplon/plat specifies the oblique pole for the great or small cir‐
227 cles. Only needed for great circles if +q is given.
228
229 +p[-][pen] sets the vector pen attributes. If pen has a leading -
230 then the head outline is not drawn. [Default pen is used, and head
231 outline is drawn]
232
233 +q means the input angle, length data instead represent the start
234 and stop opening angles of the arc segment relative to the given
235 point.
236
237 +r draws half-arrows, using only the right side of specified heads
238 [both sides].
239
240 +t[b|e]trim will shift the beginning or end point (or both) along
241 the vector segment by the given trim; append suitable unit. If the
242 modifiers b|e are not used then trim may be two values separated by
243 a slash, which is used to specify different trims for the two ends.
244 Positive trims will shorted the vector while negative trims will
245 lengthen it [no trim].
246
247 In addition, all but circular vectors may take these modifiers:
248 +jjust determines how the input x,y point relates to the vector.
249 Choose from beginning [default], end, or center.
250
251 +s means the input angle, length are instead the x, y coordinates of
252 the vector end point.
253
254 Finally, Cartesian vectors may take these modifiers:
255 +zscale[unit] expects input dx,dy vector components and uses the
256 scale to convert to polar coordinates with length in given unit.
257
259 To plot a half circle rose diagram of the data in the file fault_seg‐
260 ments.az_r (containing pairs of (azimuth, length in meters), using a 10
261 degree bin sector width, on a circle of radius = 3 inch, grid going out
262 to radius = 150 km in steps of 25 km with a 30 degree sector interval,
263 radial direction annotated every 50 km, using a light blue shading out‐
264 lined by a solid red pen (width = 0.75 points), draw the mean azimuth,
265 and shown in Portrait orientation, use:
266
267 gmt psrose fault_segments.az_r -R0/150/-90/90 -Bx50g25+l"Fault length"
268 -Byg30 -B+t"Rose diagram"-S3i -Ar10 -Glightblue
269 -W0.75p,red -Z0.001 -Cm -P -T -: > half_rose.ps
270
271 To plot a full circle wind rose diagram of the data in the file
272 lines.r_az, on a circle of radius = 5 cm, grid going out to radius =
273 500 units in steps of 100 with a 45 degree sector interval, using a
274 solid pen (width = 0.5 point, and shown in landscape [Default] orienta‐
275 tion with UNIX timestamp and command line plotted, use:
276
277 gmt psrose lines.az_r -R0/500/0/360 -S5c -Bxg100 -Byg45 -B+t"Windrose diagram" -W0.5p -Uc | lpr
278
279 Redo the same plot but this time add orange vector heads to each direc‐
280 tion (with nominal head size 0.5 cm but this will be reduced linearly
281 for lengths less than 1 cm) and save the plot, use:
282
283 gmt psrose lines.az_r -R0/500/0/360 -S5c -Bxg100 -Byg45 -B+t"Windrose diagram" -M0.5c+e+gorange+n1c -W0.5p -Uc > rose.ps
284
286 No default radial scale and grid settings for polar histograms. User
287 must run psrose -I to find max length in binned data set.
288
290 Berens, P., 2009, CircStat: A MATLAB Toolbox for Circular Statistics,
291 J. Stat. Software, 31(10), 1-21.
292
294 gmt, gmt.conf, gmtcolors, pshistogram
295
297 2019, P. Wessel, W. H. F. Smith, R. Scharroo, J. Luis, and F. Wobbe
298
299
300
301
3025.4.5 Feb 24, 2019 PSROSE(1)