Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

psxy.rst 4.4 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
  1. .. index:: ! psxy
  2. .. include:: module_core_purpose.rst_
  3. ****
  4. psxy
  5. ****
  6. |psxy_purpose|
  7. Synopsis
  8. --------
  9. .. include:: common_SYN_OPTs.rst_
  10. **gmt psxy** [ *table* ] |-J|\ *parameters*
  11. |SYN_OPT-Rz|
  12. [ |-A|\ [**m**\|\ **p**\|\ **x**\|\ **y**] ]
  13. [ |SYN_OPT-B| ]
  14. [ |-C|\ *cpt* ]
  15. [ |-D|\ *dx*/*dy* ]
  16. [ |-E|\ [**x**\|\ **y**\|\ **X**\|\ **Y**][**+a**][**+cl**\|\ **f**][**+n**][**+w**\ *cap*][**+p**\ *pen*] ]
  17. [ |-F|\ [**c**\|\ **n**\|\ **r**][**a**\|\ **f**\|\ **s**\|\ **r**\|\ *refpoint*] ]
  18. [ |-G|\ *fill* ]
  19. [ |-I|\ [*intens*] ]
  20. [ |-K| ]
  21. [ |-L|\ [**+b**\|\ **d**\|\ **D**][**+xl**\|\ **r**\|\ *x0*][**+yl**\|\ **r**\|\ *y0*][**+p**\ *pen*] ]
  22. [ |-N|\ [**c**\|\ **r**] ]
  23. [ |-O| ] [ |-P| ]
  24. [ |-S|\ [*symbol*][*size* ]
  25. [ |-T| ]
  26. [ |SYN_OPT-U| ]
  27. [ |SYN_OPT-V| ]
  28. [ |-W|\ [*pen*][*attr*] ]
  29. [ |SYN_OPT-X| ]
  30. [ |SYN_OPT-Y| ]
  31. [ |-Z|\ *value* [**+f**\|\ **l**]]
  32. [ |SYN_OPT-a| ]
  33. [ |SYN_OPT-bi| ]
  34. [ |SYN_OPT-di| ]
  35. [ |SYN_OPT-e| ]
  36. [ |SYN_OPT-f| ]
  37. [ |SYN_OPT-g| ]
  38. [ |SYN_OPT-h| ]
  39. [ |SYN_OPT-i| ]
  40. [ |SYN_OPT-p| ]
  41. [ |SYN_OPT-qi| ]
  42. [ |SYN_OPT-t| ]
  43. [ |SYN_OPT-:| ]
  44. [ |SYN_OPT--| ]
  45. .. include:: plot_common.rst_
  46. .. include:: common_classic.rst_
  47. Examples
  48. --------
  49. .. include:: explain_example.rst_
  50. To plot solid red circles (diameter = 0.2 cm) at the positions listed
  51. in the file DSDP.txt on a Mercator map at 0.3 cm/degree of the area 100E to
  52. 160E, 20S to 30N, with automatic tick-marks and gridlines, use
  53. ::
  54. gmt psxy DSDP.txt -R100/160/-20/30 -Jm0.3c -Sc0.2c -Gred -Bafg > map.ps
  55. To plot the xyz values in the file quakes.xyzm as circles with size
  56. given by the magnitude in the 4th column and color based on the depth in
  57. the third using the CPT rgb.cpt on a linear map, use
  58. ::
  59. gmt psxy quakes.xyzm -R0/1000/0/1000 -JX6i -Sc -Crgb -B200 > map.ps
  60. To plot the file trench.txt on a Mercator map, with white triangles with
  61. sides 0.25 inch on the left side of the line, spaced every 0.8 inch, use
  62. ::
  63. gmt psxy trench.txt -R150/200/20/50 -Jm0.15i -Sf0.8i/0.1i+l+t -Gwhite -W -Baf > map.ps
  64. To plot a point with color dictated by the *t.cpt* file for the *z*-value 65, try
  65. ::
  66. echo 175 30 | gmt psxy -R150/200/20/50 -JX15c -Sc0.5c -Zf65 -Ct.cpt > map.ps
  67. To plot the data in the file misc.txt as symbols determined by the code in
  68. the last column, and with size given by the magnitude in the 4th column,
  69. and color based on the third column via the CPT chrome on a
  70. linear map, use
  71. ::
  72. gmt psxy misc.txt -R0/100/-50/100 -JX6i -S -Cchrome -B20 > map.ps
  73. If you need to place vectors on a plot you can choose among
  74. straight Cartesian vectors, math circular vectors, or geo-vectors (these
  75. form small or great circles on the Earth). These can have optional heads at either
  76. end, and heads may be the traditional arrow, a circle, or a terminal cross-line.
  77. To place a few vectors with
  78. a circle at the start location and an arrow head at the end, try
  79. ::
  80. gmt psxy -R0/50/-50/50 -JX6i -Sv0.15i+bc+ea -Gyellow -W0.5p -Baf << EOF > map.ps
  81. 10 10 45 2i
  82. 30 -20 0 1.5i
  83. EOF
  84. To plot vectors (red vector heads, solid stem) from the file data.txt that contains
  85. record of the form lon, lat, dx, dy, where dx, dy are the Cartesian
  86. vector components given in user units, and these user units should be converted
  87. to cm given the scale 3.60, try
  88. ::
  89. gmt psxy -R20/40/-20/0 -JM6i -Sv0.15i+e+z3.6c -Gred -W0.25p -Baf data.txt > map.ps
  90. .. include:: plot_notes.rst_
  91. See Also
  92. --------
  93. :doc:`gmt`, :doc:`gmt.conf`,
  94. :doc:`gmtcolors`,
  95. :doc:`psbasemap`, :doc:`psxyz`
  96. .. ------------------------------------- Examples per option -------------------
  97. .. |ex_OPT-L| raw:: html
  98. <a href="#openModal">Example</a>
  99. <div id="openModal" class="modalDialog">
  100. <div>
  101. <a href="#close" title="Close" class="close">X</a>
  102. <h2>-L example</h2>
  103. <p>
  104. ps=filler.ps</br>
  105. cat << EOF > t.txt</br>
  106. 1 1</br>
  107. 2 3</br>
  108. 3 2</br>
  109. 4 4</br>
  110. EOF</br>
  111. gmt psxy -R0/5/0/5 -JX3i -P -K -B0 t.txt -Gred -W2p -L+yb > $ps</br>
  112. gmt psxy -R -J -O -K -B0 t.txt -Gred -W2p -L+yt -X3.25i >> $ps</br>
  113. gmt psxy -R -J -O -K -B0 t.txt -Gred -W2p -L+xl -X-3.25i -Y3.25i >> $ps</br>
  114. gmt psxy -R -J -O -K -B0 t.txt -Gred -W2p -L+xr -X3.25i >> $ps</br>
  115. gmt psxy -R -J -O -K -B0 t.txt -Gred -W2p -L+y4 -X-3.25i -Y3.25i >> $ps</br>
  116. gmt psxy -R -J -O -K -B0 t.txt -Gred -W2p -L+x4.5 -X3.25i >> $ps</br>
  117. gmt psxy -R -J -O -T >> $ps</br>
  118. </p>
  119. </div>
  120. </div>
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...