| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
from Magics.macro import * |
| 12 |
|
| 13 |
ref = 'symbol_ww' |
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
output = output(output_formats=['png', "ps"], |
| 18 |
output_name_first_page_number='off', |
| 19 |
output_name=ref) |
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
area = mmap(subpage_map_projection='cartesian', |
| 25 |
subpage_frame='off', |
| 26 |
subpage_x_max=100., |
| 27 |
subpage_x_min=0., |
| 28 |
subpage_y_max=120., |
| 29 |
subpage_y_min=0., |
| 30 |
page_y_length= 21., |
| 31 |
subpage_y_length= 21.) |
| 32 |
|
| 33 |
lines = ['Symbol List', "<font size='0.5'> Present Weather symbols</font>", ""] |
| 34 |
|
| 35 |
text = mtext(text_lines= lines, |
| 36 |
text_html= 'true', |
| 37 |
text_justification= 'centre', |
| 38 |
text_font_size= 1., |
| 39 |
text_colour= 'charcoal', |
| 40 |
) |
| 41 |
|
| 42 |
lines2 = ['Symbol List', "<font size='0.5'> Cloud symbols</font>", ""] |
| 43 |
|
| 44 |
text2 = mtext(text_lines= lines2, |
| 45 |
text_html= 'true', |
| 46 |
text_justification= 'centre', |
| 47 |
text_font_size= 1., |
| 48 |
text_colour= 'charcoal', |
| 49 |
) |
| 50 |
|
| 51 |
out = [] |
| 52 |
|
| 53 |
for p in range(0,9,2) : |
| 54 |
out.append(area) |
| 55 |
|
| 56 |
y = 100. |
| 57 |
x = 30. |
| 58 |
sizes = [1.,] |
| 59 |
|
| 60 |
for i in range(0,20) : |
| 61 |
|
| 62 |
if (i % 10) == 0: |
| 63 |
y = 100. |
| 64 |
x += 45. |
| 65 |
|
| 66 |
if (i % 20) == 0: |
| 67 |
y = 100. |
| 68 |
x = 30. |
| 69 |
out.append(page()) |
| 70 |
out.append(area) |
| 71 |
out.append(text) |
| 72 |
|
| 73 |
|
| 74 |
name = "ww_%02d" % ( i + p*10) |
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
xx = x |
| 79 |
for size in sizes: |
| 80 |
title = "symbol = %s"% name |
| 81 |
|
| 82 |
out.append(minput(input_x_values=[xx], |
| 83 |
input_y_values=[y], |
| 84 |
)) |
| 85 |
|
| 86 |
|
| 87 |
out.append(msymb( |
| 88 |
legend='off', |
| 89 |
symbol_type='marker', |
| 90 |
symbol_colour='evergreen', |
| 91 |
symbol_height=size, |
| 92 |
symbol_marker_mode = "name", |
| 93 |
symbol_marker_name = name, |
| 94 |
symbol_text_position='left', |
| 95 |
symbol_text_font_size=0.5, |
| 96 |
symbol_text_font_colour='black', |
| 97 |
symbol_text_list=[title], |
| 98 |
symbol_outline="off", |
| 99 |
symbol_outline_colour="navy", |
| 100 |
symbol_outline_thickness=3, |
| 101 |
)) |
| 102 |
xx+=15 |
| 103 |
y -= 10. |
| 104 |
out.append(page()) |
| 105 |
|
| 106 |
|
| 107 |
|
| 108 |
|
| 109 |
|
| 110 |
out.append(page()) |
| 111 |
out.append(area) |
| 112 |
out.append(text2) |
| 113 |
|
| 114 |
xxx=15. |
| 115 |
clouds = ['N','W','CL','CM','CH','C','a','DS'] |
| 116 |
for c in clouds: |
| 117 |
for i in range(0,10): |
| 118 |
name = c+"_%d" % i |
| 119 |
|
| 120 |
out.append(minput(input_x_values=[xxx], |
| 121 |
input_y_values=[115.-(i*10.)], |
| 122 |
)) |
| 123 |
|
| 124 |
out.append(msymb( |
| 125 |
legend='off', |
| 126 |
symbol_type='marker', |
| 127 |
symbol_colour='evergreen', |
| 128 |
symbol_height=size, |
| 129 |
symbol_marker_mode = "name", |
| 130 |
symbol_marker_name = name, |
| 131 |
symbol_text_position='left', |
| 132 |
symbol_text_font_size=0.5, |
| 133 |
symbol_text_font_colour='black', |
| 134 |
symbol_text_list=[name], |
| 135 |
symbol_outline="off", |
| 136 |
symbol_outline_colour="navy", |
| 137 |
symbol_outline_thickness=3, |
| 138 |
)) |
| 139 |
xxx+=10. |
| 140 |
|
| 141 |
|
| 142 |
|
| 143 |
|
| 144 |
plot( output, out) |
| 145 |
|