[154] | 1 | load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl" |
---|
| 2 | load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl" |
---|
| 3 | load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" |
---|
[190] | 4 | |
---|
| 5 | ;*************************************************** |
---|
| 6 | ; load ncl_preferences.ncl |
---|
| 7 | ;*************************************************** |
---|
[194] | 8 | |
---|
| 9 | function which_script() |
---|
| 10 | local script |
---|
| 11 | begin |
---|
| 12 | script="profiles" |
---|
| 13 | return(script) |
---|
| 14 | end |
---|
[190] | 15 | |
---|
| 16 | if (isfilepresent("~/ncl_preferences.ncl")) then |
---|
| 17 | loadscript("~/ncl_preferences.ncl") |
---|
| 18 | else |
---|
| 19 | if (isfilepresent("~/palm/current_version/trunk/SCRIPTS/NCL/ncl_preferences.ncl")) then |
---|
| 20 | loadscript( "~/palm/current_version/trunk/SCRIPTS/NCL/ncl_preferences.ncl") |
---|
| 21 | else |
---|
| 22 | print(" ") |
---|
| 23 | print("'ncl_preferences.ncl' does not exist in $home or $home/palm/current_version/trunk/SCRIPTS/NCL/") |
---|
| 24 | print(" ") |
---|
| 25 | exit |
---|
| 26 | end if |
---|
| 27 | end if |
---|
| 28 | |
---|
[154] | 29 | begin |
---|
| 30 | |
---|
[190] | 31 | ;*************************************************** |
---|
| 32 | ; set up default parameter values and strings |
---|
| 33 | ;*************************************************** |
---|
| 34 | |
---|
[218] | 35 | if (no_files .LT. 1 .OR. no_files .GT. 6) then |
---|
[190] | 36 | print(" ") |
---|
[218] | 37 | print("Assign 'no_files' between 1 and 6") |
---|
[190] | 38 | print(" ") |
---|
| 39 | exit |
---|
[175] | 40 | end if |
---|
[190] | 41 | |
---|
[218] | 42 | file_in = new(no_files,string) |
---|
| 43 | file_in_1 = new(no_files,logical) |
---|
| 44 | start_f = new(no_files,integer) |
---|
| 45 | end_f = new(no_files,integer) |
---|
| 46 | |
---|
[190] | 47 | if (file_1 .EQ. "File in") then |
---|
| 48 | print(" ") |
---|
[218] | 49 | print("Declare 1st input file 'file_1=' in 'ncl_preferences.ncl' or prompt") |
---|
[190] | 50 | print(" ") |
---|
| 51 | exit |
---|
[175] | 52 | else |
---|
| 53 | file_in(0) = file_1 |
---|
[218] | 54 | end if |
---|
| 55 | file_in_1(0) = False |
---|
| 56 | if (isStrSubset(file_in(0), ".nc"))then |
---|
| 57 | start_f_1 = -2 |
---|
| 58 | end_f_1 = -2 |
---|
| 59 | file_in_1(0) = True |
---|
| 60 | end if |
---|
| 61 | if (start_f_1 .EQ. -1)then |
---|
[175] | 62 | print(" ") |
---|
[218] | 63 | print("'start_f_1' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 64 | print(" ") |
---|
| 65 | exit |
---|
| 66 | end if |
---|
| 67 | if (end_f_1 .EQ. -1)then |
---|
[175] | 68 | print(" ") |
---|
[218] | 69 | print("'end_f_1' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 70 | print(" ") |
---|
[175] | 71 | exit |
---|
[218] | 72 | end if |
---|
| 73 | start_f(0) = start_f_1 |
---|
| 74 | end_f(0) = end_f_1 |
---|
| 75 | |
---|
[190] | 76 | if (prof3d .EQ. -1)then |
---|
| 77 | print(" ") |
---|
[218] | 78 | print("Set 'prof3d' to 0 or 1") |
---|
[190] | 79 | print(" ") |
---|
| 80 | exit |
---|
| 81 | else |
---|
| 82 | if (prof3d .NE. 0 .AND. prof3d .NE. 1)then |
---|
| 83 | print(" ") |
---|
| 84 | print("'prof3d'= "+prof3d+" is invalid; set 'prof3d' to 0 or 1") |
---|
| 85 | print(" ") |
---|
| 86 | exit |
---|
| 87 | end if |
---|
| 88 | end if |
---|
| 89 | |
---|
[175] | 90 | if (no_files .GT. 1) then |
---|
[190] | 91 | if (file_2 .EQ. "File in") then |
---|
| 92 | print(" ") |
---|
[218] | 93 | print("Declare 2nd input file 'file_2=' in 'ncl_preferences.ncl' or prompt") |
---|
[190] | 94 | print(" ") |
---|
| 95 | exit |
---|
[175] | 96 | else |
---|
[190] | 97 | file_in(1) = file_2 |
---|
[218] | 98 | end if |
---|
| 99 | file_in_1(1) = False |
---|
| 100 | if (isStrSubset(file_in(1), ".nc"))then |
---|
[219] | 101 | start_f_2 = -2 |
---|
| 102 | end_f_2 = -2 |
---|
[218] | 103 | file_in_1(1) = True |
---|
[175] | 104 | end if |
---|
[218] | 105 | if (start_f_2 .EQ. -1)then |
---|
[175] | 106 | print(" ") |
---|
[218] | 107 | print("'start_f_2' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 108 | print(" ") |
---|
| 109 | exit |
---|
| 110 | end if |
---|
| 111 | if (end_f_2 .EQ. -1)then |
---|
[175] | 112 | print(" ") |
---|
[218] | 113 | print("'end_f_2' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 114 | print(" ") |
---|
[175] | 115 | exit |
---|
[218] | 116 | end if |
---|
| 117 | start_f(1) = start_f_2 |
---|
| 118 | end_f(1) = end_f_2 |
---|
| 119 | end if |
---|
[190] | 120 | |
---|
[175] | 121 | if (no_files .GT. 2) then |
---|
[190] | 122 | if (file_3 .EQ. "File in") then |
---|
| 123 | print(" ") |
---|
[218] | 124 | print("Declare 3rd input file 'file_3=' in 'ncl_preferences.ncl' or prompt") |
---|
[190] | 125 | print(" ") |
---|
| 126 | exit |
---|
[175] | 127 | else |
---|
[190] | 128 | file_in(2) = file_3 |
---|
[218] | 129 | end if |
---|
| 130 | file_in_1(2) = False |
---|
| 131 | if (isStrSubset(file_in(2), ".nc"))then |
---|
[219] | 132 | start_f_3 = -2 |
---|
| 133 | end_f_3 = -2 |
---|
[218] | 134 | file_in_1(2) = True |
---|
[175] | 135 | end if |
---|
[218] | 136 | if (start_f_3 .EQ. -1)then |
---|
[175] | 137 | print(" ") |
---|
[218] | 138 | print("'start_f_3' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 139 | print(" ") |
---|
| 140 | exit |
---|
| 141 | end if |
---|
| 142 | if (end_f_3 .EQ. -1)then |
---|
[175] | 143 | print(" ") |
---|
[218] | 144 | print("'end_f_3' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 145 | print(" ") |
---|
[175] | 146 | exit |
---|
[218] | 147 | end if |
---|
| 148 | start_f(2) = start_f_3 |
---|
| 149 | end_f(2) = end_f_3 |
---|
[175] | 150 | end if |
---|
[190] | 151 | |
---|
[175] | 152 | if (no_files .GT. 3) then |
---|
[190] | 153 | if (file_4 .EQ. "File in") then |
---|
| 154 | print(" ") |
---|
[218] | 155 | print("Declare 4th input file 'file_4=' in 'ncl_preferences.ncl' or prompt") |
---|
[190] | 156 | print(" ") |
---|
| 157 | exit |
---|
[175] | 158 | else |
---|
[190] | 159 | file_in(3) = file_4 |
---|
[218] | 160 | end if |
---|
| 161 | file_in_1(3) = False |
---|
| 162 | if (isStrSubset(file_in(3), ".nc"))then |
---|
[219] | 163 | start_f_4 = -2 |
---|
| 164 | end_f_4 = -2 |
---|
[218] | 165 | file_in_1(3) = True |
---|
[175] | 166 | end if |
---|
[218] | 167 | if (start_f_4 .EQ. -1)then |
---|
[175] | 168 | print(" ") |
---|
[218] | 169 | print("'start_f_4' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 170 | print(" ") |
---|
| 171 | exit |
---|
| 172 | end if |
---|
| 173 | if (end_f_4 .EQ. -1)then |
---|
[175] | 174 | print(" ") |
---|
[218] | 175 | print("'end_f_4' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 176 | print(" ") |
---|
[175] | 177 | exit |
---|
[218] | 178 | end if |
---|
| 179 | start_f(3) = start_f_4 |
---|
| 180 | end_f(3) = end_f_4 |
---|
[175] | 181 | end if |
---|
[190] | 182 | |
---|
[175] | 183 | if (no_files .GT. 4) then |
---|
[190] | 184 | if (file_5 .EQ. "File in") then |
---|
| 185 | print(" ") |
---|
[218] | 186 | print("Declare 5th input file 'file_5=' in 'ncl_preferences.ncl' or prompt") |
---|
[190] | 187 | print(" ") |
---|
| 188 | exit |
---|
[175] | 189 | else |
---|
[190] | 190 | file_in(4) = file_5 |
---|
[218] | 191 | end if |
---|
| 192 | file_in_1(4) = False |
---|
| 193 | if (isStrSubset(file_in(4), ".nc"))then |
---|
[219] | 194 | start_f_5 = -2 |
---|
| 195 | end_f_5 = -2 |
---|
[218] | 196 | file_in_1(4) = True |
---|
[175] | 197 | end if |
---|
[218] | 198 | if (start_f_5 .EQ. -1)then |
---|
[175] | 199 | print(" ") |
---|
[218] | 200 | print("'start_f_5' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 201 | print(" ") |
---|
| 202 | exit |
---|
| 203 | end if |
---|
| 204 | if (end_f_5 .EQ. -1)then |
---|
[175] | 205 | print(" ") |
---|
[218] | 206 | print("'end_f_5' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 207 | print(" ") |
---|
[175] | 208 | exit |
---|
[218] | 209 | end if |
---|
| 210 | start_f(4) = start_f_5 |
---|
| 211 | end_f(4) = end_f_5 |
---|
[175] | 212 | end if |
---|
[218] | 213 | |
---|
[175] | 214 | if (no_files .GT. 5) then |
---|
[190] | 215 | if (file_6 .EQ. "File in") then |
---|
| 216 | print(" ") |
---|
[218] | 217 | print("Declare 6th input file 'file_6=' in 'ncl_preferences.ncl' or prompt") |
---|
[190] | 218 | print(" ") |
---|
| 219 | exit |
---|
[175] | 220 | else |
---|
[190] | 221 | file_in(5) = file_6 |
---|
[218] | 222 | end if |
---|
| 223 | file_in_1(5) = False |
---|
| 224 | if (isStrSubset(file_in(5), ".nc"))then |
---|
[219] | 225 | start_f_6 = -2 |
---|
| 226 | end_f_6 = -2 |
---|
[218] | 227 | file_in_1(5) = True |
---|
[175] | 228 | end if |
---|
[218] | 229 | if (start_f_6 .EQ. -1)then |
---|
[175] | 230 | print(" ") |
---|
[218] | 231 | print("'start_f_6' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 232 | print(" ") |
---|
[175] | 233 | exit |
---|
[218] | 234 | end if |
---|
| 235 | if (end_f_6 .EQ. -1)then |
---|
[190] | 236 | print(" ") |
---|
[218] | 237 | print("'end_f_6' must be one of the cyclic numbers (at least 0) of your input file(s)") |
---|
| 238 | print(" ") |
---|
[175] | 239 | exit |
---|
[218] | 240 | end if |
---|
| 241 | start_f(5) = start_f_6 |
---|
| 242 | end_f(5) = end_f_6 |
---|
[175] | 243 | end if |
---|
[218] | 244 | |
---|
[190] | 245 | |
---|
| 246 | if (format_out .NE. "x11" .AND. format_out .NE. "pdf" .AND. format_out .NE. "eps" .AND. format_out .NE. "ps" .AND. format_out .NE. "epsi" .AND. format_out .NE. "ncgm")then |
---|
| 247 | print(" ") |
---|
| 248 | print("'format_out = "+format_out+"' is invalid and set to'x11'") |
---|
| 249 | print(" ") |
---|
| 250 | format_out="x11" |
---|
| 251 | end if |
---|
[175] | 252 | |
---|
[190] | 253 | if (over .NE. 0 .AND. over .NE. 1) then |
---|
| 254 | print(" ") |
---|
| 255 | print("'over'= "+over+" is invalid and set to 0") |
---|
| 256 | print(" ") |
---|
| 257 | over = 0 |
---|
[154] | 258 | end if |
---|
[190] | 259 | if (no_files .GT. 1) then |
---|
| 260 | over = 0 |
---|
| 261 | print(" ") |
---|
| 262 | print("If you have more than one input file - you cannot overlay variables: over is set to 0") |
---|
| 263 | print(" ") |
---|
[154] | 264 | end if |
---|
[190] | 265 | |
---|
| 266 | if (combine .NE. 0 .AND. combine .NE. 1)then |
---|
| 267 | print(" ") |
---|
| 268 | print("Your 'combine'= "+combine+" is invalid and set to 0") |
---|
| 269 | print(" ") |
---|
| 270 | combine = 0 |
---|
[154] | 271 | end if |
---|
[190] | 272 | if (no_files .GT. 1) then |
---|
| 273 | combine = 0 |
---|
| 274 | print(" ") |
---|
| 275 | print("If you have more than one input file you cannot combine variables: combine is set to 0") |
---|
| 276 | print(" ") |
---|
| 277 | end if |
---|
| 278 | if (combine .EQ. 1 .AND. number_comb .EQ. -1) then |
---|
| 279 | print(" ") |
---|
[218] | 280 | print("Set 'number_comb' to 2 or 3 or combine to 0") |
---|
[190] | 281 | print(" ") |
---|
| 282 | exit |
---|
[154] | 283 | end if |
---|
[190] | 284 | if (combine .EQ. 1)then |
---|
| 285 | if (number_comb .EQ. -1) then |
---|
| 286 | print(" ") |
---|
[218] | 287 | print("Set 'number_comb' to 2 or 3 or combine to 0") |
---|
[175] | 288 | print(" ") |
---|
[190] | 289 | exit |
---|
[175] | 290 | end if |
---|
[190] | 291 | if (number_comb .NE. 2 .AND. number_comb .NE. 3) then |
---|
| 292 | print(" ") |
---|
[218] | 293 | print("Set 'number_comb' to 2 or 3 or combine to 0") |
---|
[175] | 294 | print(" ") |
---|
| 295 | exit |
---|
| 296 | end if |
---|
[190] | 297 | end if |
---|
| 298 | if (combine .EQ. 1 .AND. c_var .EQ. "c_variables") then |
---|
| 299 | print(" ") |
---|
[218] | 300 | print("Select variables for overlaying ('c_var') or set combine to 0") |
---|
[190] | 301 | print(" ") |
---|
| 302 | exit |
---|
[174] | 303 | end if |
---|
[175] | 304 | |
---|
[218] | 305 | if (log_z .NE. 0 .AND. log_z .NE. 1)then |
---|
[190] | 306 | print(" ") |
---|
[218] | 307 | print("'log_z'= "+log_z+" is invalid and set to 0") |
---|
[190] | 308 | print(" ") |
---|
[218] | 309 | log_z = 0 |
---|
[190] | 310 | end if |
---|
| 311 | |
---|
[218] | 312 | if (norm_z .EQ. 0) then |
---|
[190] | 313 | print(" ") |
---|
[218] | 314 | print("Normalising with 0 is not allowed, 'norm_z' is set to 1.0") |
---|
[190] | 315 | print(" ") |
---|
[218] | 316 | norm_z = 1.0 |
---|
[175] | 317 | end if |
---|
| 318 | |
---|
[190] | 319 | ;*************************************************** |
---|
[154] | 320 | ; open input file |
---|
[190] | 321 | ;*************************************************** |
---|
[154] | 322 | |
---|
[175] | 323 | do nof=0,no_files-1 |
---|
[174] | 324 | |
---|
[218] | 325 | files=new(end_f(nof)-start_f(nof)+1,string) |
---|
| 326 | if (file_in_1(nof))then |
---|
| 327 | if (isfilepresent(file_in(nof)))then |
---|
[219] | 328 | files(0)=file_in(nof) |
---|
[218] | 329 | else |
---|
| 330 | print(" ") |
---|
[219] | 331 | print("1st input file: '"+file_in(nof)+"' does not exist") |
---|
[218] | 332 | print(" ") |
---|
| 333 | exit |
---|
| 334 | end if |
---|
| 335 | else |
---|
| 336 | if (start_f(nof) .EQ. 0)then |
---|
| 337 | if (isfilepresent(file_in(nof)+".nc"))then |
---|
| 338 | files(0)=file_in(nof)+".nc" |
---|
| 339 | do i=1,end_f(nof) |
---|
| 340 | if (isfilepresent(file_in(nof)+"."+i+".nc"))then |
---|
| 341 | files(i)=file_in(nof)+"."+i+".nc" |
---|
| 342 | else |
---|
| 343 | print(" ") |
---|
| 344 | print("Input file: '"+file_in(nof)+"."+i+".nc' does not exist") |
---|
| 345 | print(" ") |
---|
| 346 | exit |
---|
| 347 | end if |
---|
| 348 | end do |
---|
| 349 | else |
---|
| 350 | print(" ") |
---|
| 351 | print("Input file: '"+file_in(nof)+".nc' does not exist") |
---|
| 352 | print(" ") |
---|
| 353 | exit |
---|
| 354 | end if |
---|
| 355 | else |
---|
| 356 | do i=start_f(nof),end_f(nof) |
---|
| 357 | if (isfilepresent(file_in(nof)+"."+i+".nc"))then |
---|
| 358 | files(i-start_f(nof))=file_in(nof)+"."+i+".nc" |
---|
| 359 | else |
---|
| 360 | print(" ") |
---|
| 361 | print("Input file: '"+file_in(nof)+"."+i+".nc' does not exist") |
---|
| 362 | print(" ") |
---|
| 363 | exit |
---|
| 364 | end if |
---|
| 365 | end do |
---|
| 366 | end if |
---|
| 367 | end if |
---|
| 368 | |
---|
| 369 | f=addfiles(files,"r") |
---|
| 370 | f_att=addfile(files(0),"r") |
---|
| 371 | ListSetType(f,"cat") |
---|
[175] | 372 | |
---|
[218] | 373 | vNam = getfilevarnames(f_att) |
---|
| 374 | |
---|
[175] | 375 | if (nof .EQ. 0)then |
---|
| 376 | vNam0=vNam |
---|
| 377 | end if |
---|
| 378 | if (nof .NE. 0)then |
---|
| 379 | if (dim0 .NE. dim)then |
---|
| 380 | print(" ") |
---|
[190] | 381 | print("There are 'no_files'="+no_files+" input files but they do not contain the same variables") |
---|
[175] | 382 | print(" ") |
---|
| 383 | exit |
---|
| 384 | else |
---|
| 385 | do i=0,dim0-1 |
---|
| 386 | if (vNam0(i) .NE. vNam(i))then |
---|
| 387 | print(" ") |
---|
[190] | 388 | print("There are 'no_files'="+no_files+" input files but they do not contain the same variables") |
---|
[175] | 389 | print(" ") |
---|
| 390 | exit |
---|
| 391 | end if |
---|
| 392 | end do |
---|
| 393 | end if |
---|
| 394 | end if |
---|
| 395 | nof=nof+1 |
---|
[154] | 396 | print(" ") |
---|
[190] | 397 | print("Variables in input file "+nof+":") |
---|
| 398 | print("- "+ vNam) |
---|
[154] | 399 | print(" ") |
---|
[175] | 400 | nof=nof-1 |
---|
[161] | 401 | dim = dimsizes(vNam) |
---|
[175] | 402 | dim0=dim |
---|
[174] | 403 | |
---|
[161] | 404 | if (dim .EQ. 0) then |
---|
| 405 | print(" ") |
---|
[218] | 406 | print("There is no data on file") |
---|
[161] | 407 | print(" ") |
---|
| 408 | end if |
---|
| 409 | |
---|
[175] | 410 | ;-----------------------------------------------------below steps only for first file -> nof=0 |
---|
| 411 | if (nof .EQ. 0) then |
---|
| 412 | |
---|
| 413 | plot = new(dim,graphic) |
---|
| 414 | plot_ = new(dim,graphic) |
---|
| 415 | if (no_files .GT. 1) then |
---|
| 416 | multi_plot = new((/no_files,dim/),graphic) |
---|
| 417 | max_nof = new((/no_files,dim/),float) |
---|
| 418 | min_nof = new((/no_files,dim/),float) |
---|
| 419 | name = new((/no_files,dim/),string) |
---|
| 420 | unit_ = new((/no_files,dim/),string) |
---|
| 421 | end if |
---|
| 422 | |
---|
[174] | 423 | if (prof3d .EQ. 0) then |
---|
[175] | 424 | |
---|
[161] | 425 | do varn = dim-1,0,1 |
---|
| 426 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then |
---|
| 427 | varn=varn-1 |
---|
| 428 | continue |
---|
| 429 | end if |
---|
[175] | 430 | if (vNam(varn) .EQ. "u" .OR. isStrSubset(vNam(varn), "u_"))then |
---|
[218] | 431 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 432 | break |
---|
| 433 | else |
---|
[190] | 434 | if (vNam(varn) .EQ. "v" .OR. isStrSubset(vNam(varn), "v_"))then |
---|
[218] | 435 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 436 | break |
---|
| 437 | else |
---|
[174] | 438 | if(vNam(varn) .EQ. "pt" .OR. isStrSubset(vNam(varn), "pt_"))then |
---|
[218] | 439 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 440 | break |
---|
| 441 | else |
---|
[174] | 442 | if(vNam(varn) .EQ. "vpt" .OR. isStrSubset(vNam(varn), "vpt_"))then |
---|
[250] | 443 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 444 | break |
---|
| 445 | else |
---|
[174] | 446 | if(vNam(varn) .EQ. "lpt" .OR. isStrSubset(vNam(varn), "lpt_"))then |
---|
[218] | 447 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 448 | break |
---|
| 449 | else |
---|
[174] | 450 | if(vNam(varn) .EQ. "q" .OR. isStrSubset(vNam(varn), "q_") )then |
---|
[218] | 451 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 452 | break |
---|
| 453 | else |
---|
[174] | 454 | if(vNam(varn) .EQ. "qv" .OR. isStrSubset(vNam(varn), "qv_"))then |
---|
[218] | 455 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 456 | break |
---|
| 457 | else |
---|
[174] | 458 | if(vNam(varn) .EQ. "ql" .OR. isStrSubset(vNam(varn), "ql_"))then |
---|
[218] | 459 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 460 | break |
---|
| 461 | else |
---|
[174] | 462 | if(vNam(varn) .EQ. "rho" .OR. isStrSubset(vNam(varn), "rho_"))then |
---|
[218] | 463 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 464 | break |
---|
| 465 | else |
---|
[174] | 466 | if(vNam(varn) .EQ. "s" .OR. isStrSubset(vNam(varn), "s_") )then |
---|
[218] | 467 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 468 | break |
---|
| 469 | else |
---|
[174] | 470 | if(vNam(varn) .EQ. "sa" .OR. isStrSubset(vNam(varn), "sa_"))then |
---|
[218] | 471 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 472 | break |
---|
| 473 | else |
---|
[174] | 474 | if(vNam(varn) .EQ. "e" .OR. isStrSubset(vNam(varn), "e_"))then |
---|
[218] | 475 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 476 | break |
---|
| 477 | else |
---|
[174] | 478 | if(vNam(varn) .EQ. "es" .OR. isStrSubset(vNam(varn), "es_"))then |
---|
[218] | 479 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 480 | break |
---|
| 481 | else |
---|
[174] | 482 | if(vNam(varn) .EQ. "km" .OR. isStrSubset(vNam(varn), "km_"))then |
---|
[218] | 483 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 484 | break |
---|
| 485 | else |
---|
[174] | 486 | if(vNam(varn) .EQ. "kh" .OR. isStrSubset(vNam(varn), "kh_"))then |
---|
[218] | 487 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 488 | break |
---|
| 489 | else |
---|
[174] | 490 | if(vNam(varn) .EQ. "l" .OR. isStrSubset(vNam(varn), "l_"))then |
---|
[218] | 491 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 492 | break |
---|
| 493 | else |
---|
[174] | 494 | if(vNam(varn) .EQ. "us2" .OR. isStrSubset(vNam(varn), "us2_"))then |
---|
[218] | 495 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 496 | break |
---|
| 497 | else |
---|
[174] | 498 | if(vNam(varn) .EQ. "vs2" .OR. isStrSubset(vNam(varn), "vs2_") )then |
---|
[218] | 499 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 500 | break |
---|
| 501 | else |
---|
[174] | 502 | if(vNam(varn) .EQ. "pts2" .OR. isStrSubset(vNam(varn), "pts2_"))then |
---|
[218] | 503 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 504 | break |
---|
| 505 | else |
---|
[174] | 506 | if(vNam(varn) .EQ. "wsususodz" .OR. isStrSubset(vNam(varn), "wsususodz_"))then |
---|
[218] | 507 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 508 | break |
---|
| 509 | else |
---|
[174] | 510 | if(vNam(varn) .EQ. "wspsodz" .OR. isStrSubset(vNam(varn), "wspsodz_"))then |
---|
[218] | 511 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 512 | break |
---|
| 513 | else |
---|
[174] | 514 | if(vNam(varn) .EQ. "wpeodz" .OR. isStrSubset(vNam(varn), "wpeodz_"))then |
---|
[218] | 515 | z_u = f_att->$vNam(varn+1)$ |
---|
[161] | 516 | break |
---|
| 517 | end if |
---|
| 518 | end if |
---|
| 519 | end if |
---|
| 520 | end if |
---|
| 521 | end if |
---|
| 522 | end if |
---|
| 523 | end if |
---|
| 524 | end if |
---|
| 525 | end if |
---|
| 526 | end if |
---|
| 527 | end if |
---|
| 528 | end if |
---|
| 529 | end if |
---|
| 530 | end if |
---|
| 531 | end if |
---|
| 532 | end if |
---|
| 533 | end if |
---|
| 534 | end if |
---|
| 535 | end if |
---|
| 536 | end if |
---|
| 537 | end if |
---|
| 538 | end if |
---|
| 539 | varn=varn-1 |
---|
| 540 | end do |
---|
| 541 | |
---|
| 542 | do varn=dim-1,0,1 |
---|
| 543 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then |
---|
| 544 | varn=varn-1 |
---|
| 545 | continue |
---|
| 546 | end if |
---|
[175] | 547 | if (vNam(varn) .EQ. "w" .OR. isStrSubset(vNam(varn), "w_"))then |
---|
[218] | 548 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 549 | break |
---|
| 550 | else |
---|
[174] | 551 | if (vNam(varn) .EQ. "wpup" .OR. isStrSubset(vNam(varn), "wpup_"))then |
---|
[218] | 552 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 553 | break |
---|
| 554 | else |
---|
[174] | 555 | if(vNam(varn) .EQ. "wsus" .OR. isStrSubset(vNam(varn), "wsus_"))then |
---|
[218] | 556 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 557 | break |
---|
| 558 | else |
---|
[174] | 559 | if(vNam(varn) .EQ. "wu" .OR. isStrSubset(vNam(varn), "wu_"))then |
---|
[218] | 560 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 561 | break |
---|
| 562 | else |
---|
[174] | 563 | if(vNam(varn) .EQ. "wpvp" .OR. isStrSubset(vNam(varn), "wpvp_"))then |
---|
[218] | 564 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 565 | break |
---|
| 566 | else |
---|
[174] | 567 | if(vNam(varn) .EQ. "wsvs" .OR. isStrSubset(vNam(varn), "wsvs_"))then |
---|
[218] | 568 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 569 | break |
---|
| 570 | else |
---|
[174] | 571 | if(vNam(varn) .EQ. "wv" .OR. isStrSubset(vNam(varn), "wv_"))then |
---|
[218] | 572 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 573 | break |
---|
| 574 | else |
---|
[174] | 575 | if(vNam(varn) .EQ. "wptpp" .OR. isStrSubset(vNam(varn), "wptpp_"))then |
---|
[218] | 576 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 577 | break |
---|
| 578 | else |
---|
[174] | 579 | if(vNam(varn) .EQ. "wspts" .OR. isStrSubset(vNam(varn), "wspts_"))then |
---|
[218] | 580 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 581 | break |
---|
| 582 | else |
---|
[174] | 583 | if(vNam(varn) .EQ. "wpt" .OR. isStrSubset(vNam(varn), "wpz_"))then |
---|
[218] | 584 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 585 | break |
---|
| 586 | else |
---|
[174] | 587 | if(vNam(varn) .EQ. "wsptsBC" .OR. isStrSubset(vNam(varn), "wsptsBC_"))then |
---|
[218] | 588 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 589 | break |
---|
| 590 | else |
---|
[174] | 591 | if(vNam(varn) .EQ. "wptBC" .OR. isStrSubset(vNam(varn), "wptBC_"))then |
---|
[218] | 592 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 593 | break |
---|
| 594 | else |
---|
[174] | 595 | if(vNam(varn) .EQ. "wpvptp" .OR. isStrSubset(vNam(varn), "wpvptp_"))then |
---|
[218] | 596 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 597 | break |
---|
| 598 | else |
---|
[174] | 599 | if(vNam(varn) .EQ. "wsvpts" .OR. isStrSubset(vNam(varn), "wsvpts_"))then |
---|
[218] | 600 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 601 | break |
---|
| 602 | else |
---|
[174] | 603 | if(vNam(varn) .EQ. "wvpt" .OR. isStrSubset(vNam(varn), "wvpt_"))then |
---|
[218] | 604 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 605 | break |
---|
| 606 | else |
---|
[174] | 607 | if(vNam(varn) .EQ. "wpqp" .OR. isStrSubset(vNam(varn), "wpqp_"))then |
---|
[218] | 608 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 609 | break |
---|
| 610 | else |
---|
[174] | 611 | if(vNam(varn) .EQ. "wsqs" .OR. isStrSubset(vNam(varn), "wsqs_"))then |
---|
[218] | 612 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 613 | break |
---|
| 614 | else |
---|
[174] | 615 | if(vNam(varn) .EQ. "wq" .OR. isStrSubset(vNam(varn), "wq_"))then |
---|
[218] | 616 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 617 | break |
---|
| 618 | else |
---|
[174] | 619 | if(vNam(varn) .EQ. "wpqvp" .OR. isStrSubset(vNam(varn), "wpqvp_"))then |
---|
[218] | 620 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 621 | break |
---|
| 622 | else |
---|
[174] | 623 | if(vNam(varn) .EQ. "wsqvs" .OR. isStrSubset(vNam(varn), "wsqvs_"))then |
---|
[218] | 624 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 625 | break |
---|
| 626 | else |
---|
[174] | 627 | if(vNam(varn) .EQ. "wqv" .OR. isStrSubset(vNam(varn), "wqv_"))then |
---|
[218] | 628 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 629 | break |
---|
| 630 | else |
---|
[174] | 631 | if(vNam(varn) .EQ. "wpsp" .OR. isStrSubset(vNam(varn), "wpsp_"))then |
---|
[218] | 632 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 633 | break |
---|
| 634 | else |
---|
[174] | 635 | if(vNam(varn) .EQ. "wsss" .OR. isStrSubset(vNam(varn), "wsss_"))then |
---|
[218] | 636 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 637 | break |
---|
| 638 | else |
---|
[174] | 639 | if(vNam(varn) .EQ. "ws" .OR. isStrSubset(vNam(varn), "ws_"))then |
---|
[218] | 640 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 641 | break |
---|
| 642 | else |
---|
[174] | 643 | if(vNam(varn) .EQ. "wpsap" .OR. isStrSubset(vNam(varn), "wpsap_"))then |
---|
[218] | 644 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 645 | break |
---|
| 646 | else |
---|
[174] | 647 | if(vNam(varn) .EQ. "wssas" .OR. isStrSubset(vNam(varn), "wssas_") )then |
---|
[218] | 648 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 649 | break |
---|
| 650 | else |
---|
[174] | 651 | if(vNam(varn) .EQ. "wsa" .OR. isStrSubset(vNam(varn), "wsa_"))then |
---|
[218] | 652 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 653 | break |
---|
| 654 | else |
---|
[174] | 655 | if(vNam(varn) .EQ. "wses" .OR. isStrSubset(vNam(varn), "wses_"))then |
---|
[218] | 656 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 657 | break |
---|
| 658 | else |
---|
[174] | 659 | if(vNam(varn) .EQ. "ws2" .OR. isStrSubset(vNam(varn), "ws2_"))then |
---|
[218] | 660 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 661 | break |
---|
| 662 | else |
---|
[174] | 663 | if(vNam(varn) .EQ. "ws3" .OR. isStrSubset(vNam(varn), "ws3_"))then |
---|
[218] | 664 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 665 | break |
---|
| 666 | else |
---|
[174] | 667 | if(vNam(varn) .EQ. "Sw" .OR. isStrSubset(vNam(varn), "Sw_"))then |
---|
[218] | 668 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 669 | break |
---|
| 670 | else |
---|
[174] | 671 | if(vNam(varn) .EQ. "ws2pts".OR. isStrSubset(vNam(varn), "ws2pts_") )then |
---|
[218] | 672 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 673 | break |
---|
| 674 | else |
---|
[174] | 675 | if(vNam(varn) .EQ. "wspts2" .OR. isStrSubset(vNam(varn), "wspts2_"))then |
---|
[218] | 676 | z_w = f_att->$vNam(varn+1)$ |
---|
[161] | 677 | break |
---|
| 678 | end if |
---|
| 679 | end if |
---|
| 680 | end if |
---|
| 681 | end if |
---|
| 682 | end if |
---|
| 683 | end if |
---|
| 684 | end if |
---|
| 685 | end if |
---|
| 686 | end if |
---|
| 687 | end if |
---|
| 688 | end if |
---|
| 689 | end if |
---|
| 690 | end if |
---|
| 691 | end if |
---|
| 692 | end if |
---|
| 693 | end if |
---|
| 694 | end if |
---|
| 695 | end if |
---|
| 696 | end if |
---|
| 697 | end if |
---|
| 698 | end if |
---|
| 699 | end if |
---|
| 700 | end if |
---|
| 701 | end if |
---|
| 702 | end if |
---|
| 703 | end if |
---|
| 704 | end if |
---|
| 705 | end if |
---|
| 706 | end if |
---|
| 707 | end if |
---|
| 708 | end if |
---|
| 709 | end if |
---|
| 710 | end if |
---|
| 711 | varn=varn-1 |
---|
| 712 | end do |
---|
[190] | 713 | |
---|
| 714 | if (.not. isvar("z_u") .AND. .not. isvar ("z_w")) then |
---|
[175] | 715 | co=0 |
---|
[161] | 716 | do varn=0,dim-1 |
---|
| 717 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then |
---|
| 718 | check = False |
---|
| 719 | else |
---|
[190] | 720 | check = True |
---|
| 721 | if (var .NE. "all") then |
---|
[161] | 722 | check = isStrSubset( var,","+vNam(varn)+"," ) |
---|
[190] | 723 | end if |
---|
[161] | 724 | end if |
---|
[175] | 725 | if (check)then |
---|
| 726 | co=co+1 |
---|
[218] | 727 | z = f_att->$vNam(varn+1)$ |
---|
[190] | 728 | if (getvardims(z) .EQ. "zu")then |
---|
| 729 | z_u = z |
---|
| 730 | else |
---|
| 731 | if (getvardims(z) .EQ. "zw")then |
---|
| 732 | z_w = z |
---|
| 733 | end if |
---|
| 734 | end if |
---|
[161] | 735 | dimz = dimsizes(z) |
---|
| 736 | break |
---|
| 737 | end if |
---|
| 738 | end do |
---|
[175] | 739 | if (co .EQ. 0) then |
---|
| 740 | print(" ") |
---|
[190] | 741 | print("The variables 'var="+var+"' do not exist on your input file;") |
---|
| 742 | print("be sure to have one comma berfore and after each variable") |
---|
[175] | 743 | print(" ") |
---|
| 744 | exit |
---|
| 745 | end if |
---|
[161] | 746 | end if |
---|
[175] | 747 | |
---|
[162] | 748 | if (isvar("z_u") ) then |
---|
| 749 | dimz = dimsizes(z_u) |
---|
| 750 | else |
---|
| 751 | if (isvar("z_w"))then |
---|
| 752 | dimz = dimsizes(z_w) |
---|
| 753 | end if |
---|
| 754 | end if |
---|
[174] | 755 | |
---|
| 756 | else |
---|
| 757 | |
---|
| 758 | do varn = dim-1,0,1 |
---|
[175] | 759 | if (vNam(varn) .EQ. "zu_3d")then |
---|
[218] | 760 | z_u = f_att->zu_3d |
---|
[174] | 761 | dimz = dimsizes(z_u) |
---|
| 762 | else |
---|
[175] | 763 | if (vNam(varn) .EQ. "zw_3d")then |
---|
[218] | 764 | z_w = f_att->zw_3d |
---|
[174] | 765 | dimz = dimsizes(z_w) |
---|
| 766 | end if |
---|
| 767 | end if |
---|
[218] | 768 | if (vNam(varn) .EQ. "x")then |
---|
| 769 | x = f_att->x |
---|
| 770 | dimx=dimsizes(x) |
---|
| 771 | else |
---|
| 772 | if (vNam(varn) .EQ. "xu")then |
---|
| 773 | x = f_att->xu |
---|
| 774 | dimx=dimsizes(x) |
---|
| 775 | end if |
---|
| 776 | end if |
---|
| 777 | if (vNam(varn) .EQ. "y")then |
---|
| 778 | y = f_att->y |
---|
| 779 | dimy=dimsizes(y) |
---|
| 780 | else |
---|
| 781 | if (vNam(varn) .EQ. "yv")then |
---|
| 782 | y = f_att->yv |
---|
| 783 | dimy=dimsizes(y) |
---|
| 784 | end if |
---|
| 785 | end if |
---|
[174] | 786 | end do |
---|
| 787 | |
---|
| 788 | end if |
---|
| 789 | |
---|
[190] | 790 | if(.not. isvar("z_u") .AND. .not. isvar("z_w"))then |
---|
| 791 | print(" ") |
---|
| 792 | print("Program aborts - there are no z-variables available") |
---|
[218] | 793 | print("Be sure if 'plot_3d' is set correctly") |
---|
[190] | 794 | print(" ") |
---|
| 795 | exit |
---|
| 796 | end if |
---|
| 797 | |
---|
[218] | 798 | if (prof3d .EQ. 1)then |
---|
| 799 | t_all = f[:]->time |
---|
[236] | 800 | nt = dimsizes(t_all) |
---|
[218] | 801 | else |
---|
[236] | 802 | t_all = f[:]->time |
---|
| 803 | nt = dimsizes(t_all) |
---|
| 804 | t_null = False |
---|
| 805 | if (t_all(0) .EQ. 0 .AND. nt .GT. 1)then |
---|
| 806 | delete(t_all) |
---|
| 807 | t_all = f[:]->time(1:) |
---|
| 808 | nt = dimsizes(t_all) |
---|
| 809 | t_null = True |
---|
| 810 | end if |
---|
[218] | 811 | end if |
---|
[236] | 812 | |
---|
[162] | 813 | delta_t=t_all(nt-1)/nt |
---|
[174] | 814 | |
---|
[154] | 815 | ; **************************************************** |
---|
| 816 | ; start of time step and different types of mistakes that could be done |
---|
| 817 | ; **************************************************** |
---|
[175] | 818 | |
---|
[190] | 819 | if (start_time_step .EQ. -1.) then |
---|
| 820 | start_time_step=t_all(0)/3600 |
---|
[154] | 821 | else |
---|
[175] | 822 | if (start_time_step .GT. t_all(nt-1)/3600)then |
---|
[154] | 823 | print(" ") |
---|
[162] | 824 | print("'start_time_step' = "+ start_time_step +"h is greater than last time step = " + t_all(nt-1)+"s = "+t_all(nt-1)/3600+"h") |
---|
[154] | 825 | print(" ") |
---|
[218] | 826 | print("Select another 'start_time_step'") |
---|
[162] | 827 | print(" ") |
---|
[154] | 828 | exit |
---|
| 829 | end if |
---|
[175] | 830 | if (start_time_step .LT. t_all(0)/3600)then |
---|
[154] | 831 | print(" ") |
---|
[174] | 832 | print("'start_time_step' = "+ start_time_step +"h is lower than first time step = " + t_all(0)+"s = "+t_all(0)/3600+"h") |
---|
[190] | 833 | print(" ") |
---|
[154] | 834 | exit |
---|
| 835 | end if |
---|
| 836 | end if |
---|
[175] | 837 | |
---|
[218] | 838 | do i=0,nt-1 |
---|
[190] | 839 | if (start_time_step .GE. (t_all(i)-delta_t/2)/3600 .AND. start_time_step .LT. (t_all(i)+delta_t/2)/3600)then |
---|
[162] | 840 | st=i |
---|
| 841 | break |
---|
| 842 | end if |
---|
| 843 | end do |
---|
[190] | 844 | if (.not. isvar("st"))then |
---|
| 845 | print(" ") |
---|
| 846 | print("'start_time_step' = "+ start_time_step +"h is invalid") |
---|
| 847 | print(" ") |
---|
[218] | 848 | print("Select another 'start_time_step'") |
---|
[190] | 849 | print(" ") |
---|
| 850 | exit |
---|
| 851 | end if |
---|
[174] | 852 | |
---|
[154] | 853 | ; **************************************************** |
---|
| 854 | ; end of time step and different types of mistakes that could be done |
---|
| 855 | ; **************************************************** |
---|
| 856 | |
---|
[190] | 857 | if (end_time_step .EQ. -1.) then |
---|
| 858 | end_time_step = t_all(nt-1)/3600 |
---|
[154] | 859 | else |
---|
[175] | 860 | if (end_time_step .GT. t_all(nt-1)/3600)then |
---|
[154] | 861 | print(" ") |
---|
[162] | 862 | print("'end_time_step' = "+ end_time_step +"h is greater than last time step = " + t_all(nt-1)+"s = "+t_all(nt-1)/3600+"h") |
---|
[154] | 863 | print(" ") |
---|
[218] | 864 | print("Select another 'end_time_step'") |
---|
[162] | 865 | print(" ") |
---|
[154] | 866 | exit |
---|
| 867 | end if |
---|
[175] | 868 | if (end_time_step .LT. start_time_step/3600)then |
---|
[154] | 869 | print(" ") |
---|
[162] | 870 | print("'end_time_step' = "+ end_time_step +"h is lower than 'start_time_step' = "+start_time_step+"h") |
---|
[154] | 871 | print(" ") |
---|
[218] | 872 | print("Select another 'start_time_step' or 'end_time_step'") |
---|
[162] | 873 | print(" ") |
---|
[154] | 874 | exit |
---|
| 875 | end if |
---|
[162] | 876 | end if |
---|
[175] | 877 | |
---|
[174] | 878 | do i=0,nt-1 |
---|
[190] | 879 | if (end_time_step .GE. (t_all(i)-delta_t/2)/3600 .AND. end_time_step .LT. (t_all(i)+delta_t/2)/3600)then |
---|
[162] | 880 | et=i |
---|
| 881 | break |
---|
[154] | 882 | end if |
---|
[162] | 883 | end do |
---|
[190] | 884 | if (.not. isvar("et"))then |
---|
| 885 | print(" ") |
---|
| 886 | print("'end_time_step' = "+ end_time_step +"h is invalid") |
---|
| 887 | print(" ") |
---|
[218] | 888 | print("Select another 'end_time_step'") |
---|
[190] | 889 | print(" ") |
---|
| 890 | exit |
---|
| 891 | end if |
---|
[154] | 892 | |
---|
[162] | 893 | delete(start_time_step) |
---|
| 894 | start_time_step=round(st,3) |
---|
| 895 | delete(end_time_step) |
---|
| 896 | end_time_step=round(et,3) |
---|
| 897 | |
---|
[175] | 898 | print(" ") |
---|
| 899 | print("Output of time steps from "+t_all(start_time_step)/3600+" h = "+t_all(start_time_step)+" s => index = "+start_time_step) |
---|
| 900 | print(" till "+t_all(end_time_step)/3600+" h = "+t_all(end_time_step)+" s => index = "+end_time_step) |
---|
| 901 | print(" ") |
---|
| 902 | |
---|
[154] | 903 | ; **************************************************** |
---|
| 904 | ; set up legend and colors |
---|
| 905 | ; **************************************************** |
---|
| 906 | |
---|
[161] | 907 | legend_label=new(nt,double) |
---|
[154] | 908 | do p=start_time_step,end_time_step |
---|
[236] | 909 | legend_label(p-start_time_step)=decimalPlaces(t_all(p)/3600,3,True) |
---|
[154] | 910 | end do |
---|
| 911 | |
---|
[162] | 912 | np = end_time_step-start_time_step+1 |
---|
[154] | 913 | |
---|
| 914 | ; *************************************************** |
---|
| 915 | ; set up recourses |
---|
| 916 | ; *************************************************** |
---|
| 917 | |
---|
[175] | 918 | res = True |
---|
[154] | 919 | res@gsnDraw = False |
---|
| 920 | res@gsnFrame = False |
---|
| 921 | res@gsnPaperOrientation = "portrait" |
---|
| 922 | res@gsnPaperWidth = 8.27 |
---|
| 923 | res@gsnPaperHeight = 11.69 |
---|
| 924 | res@gsnPaperMargin = 0.79 |
---|
| 925 | res@txFont = "helvetica" |
---|
| 926 | res@tiMainFont = "helvetica" |
---|
| 927 | res@tiXAxisFont = "helvetica" |
---|
| 928 | res@tiYAxisFont = "helvetica" |
---|
| 929 | res@tmXBLabelFont = "helvetica" |
---|
| 930 | res@tmYLLabelFont = "helvetica" |
---|
| 931 | res@lgLabelFont = "helvetica" |
---|
| 932 | res@tmLabelAutoStride = True |
---|
[219] | 933 | if (legend .EQ. 1)then |
---|
| 934 | res@pmLegendDisplayMode = "Always" |
---|
| 935 | end if |
---|
[154] | 936 | res@pmLegendSide = "Top" |
---|
| 937 | res@xyExplicitLegendLabels = legend_label |
---|
[161] | 938 | res@pmLegendParallelPosF = 1.15 |
---|
| 939 | res@pmLegendOrthogonalPosF = -1.0 |
---|
[154] | 940 | res@pmLegendWidthF = 0.12 |
---|
[250] | 941 | res@pmLegendHeightF = 0.05*(end_time_step-start_time_step+1) |
---|
[218] | 942 | res@lgLabelFontHeightF = font_size |
---|
[190] | 943 | res@lgTitleString = "Time [h]" |
---|
[218] | 944 | res@lgTitleFontHeightF = font_size |
---|
| 945 | res@txFontHeightF = font_size |
---|
| 946 | res@tiXAxisFontHeightF = font_size |
---|
| 947 | res@tiYAxisFontHeightF = font_size |
---|
| 948 | res@tmXBLabelFontHeightF = font_size |
---|
| 949 | res@tmYLLabelFontHeightF = font_size |
---|
[175] | 950 | res@tiXAxisString = " " |
---|
| 951 | if ( black .eq. 0 ) then |
---|
[250] | 952 | res@xyLineColors = -(ispan(-237,-2,235/np)) |
---|
[175] | 953 | end if |
---|
[218] | 954 | if (norm_z .EQ. 1)then |
---|
[175] | 955 | res@tiYAxisString = "Height [m]" |
---|
| 956 | else |
---|
[218] | 957 | res@tiYAxisString = "Height / "+norm_z+" [m]" |
---|
[175] | 958 | end if |
---|
| 959 | |
---|
[218] | 960 | if (log_z .EQ. 1) then |
---|
[175] | 961 | res@trYLog = True |
---|
| 962 | end if |
---|
| 963 | |
---|
[190] | 964 | if (dash .EQ. 0 ) then |
---|
[175] | 965 | res@xyMonoDashPattern = True |
---|
| 966 | else |
---|
[250] | 967 | res@xyMonoDashPattern = False |
---|
[175] | 968 | if (no_files .GT. 1) |
---|
[219] | 969 | res@xyMonoDashPattern = True |
---|
[175] | 970 | print(" ") |
---|
| 971 | print("If you use more than one file, patterns for different timesteps cannot be used") |
---|
| 972 | print(" ") |
---|
[190] | 973 | end if |
---|
[154] | 974 | end if |
---|
[250] | 975 | |
---|
[218] | 976 | res@tmXBMinorPerMajor = 4 |
---|
| 977 | res@tmYLMinorPerMajor = 4 |
---|
[154] | 978 | |
---|
| 979 | resP = True |
---|
| 980 | resP@txFont = "helvetica" |
---|
[218] | 981 | resP@txString = f_att@title |
---|
[154] | 982 | resP@txFuncCode = "~" |
---|
[218] | 983 | resP@txFontHeightF = 0.015 |
---|
[154] | 984 | |
---|
| 985 | ; *************************************************** |
---|
[161] | 986 | ; set up graphics for plot |
---|
[154] | 987 | ; *************************************************** |
---|
[161] | 988 | |
---|
[154] | 989 | if (combine .EQ. 1) then |
---|
[190] | 990 | plot_o = new(number_comb,graphic) |
---|
[161] | 991 | label=new(number_comb,string) |
---|
| 992 | color_o=new(number_comb,integer) |
---|
| 993 | mini=new(number_comb,float) |
---|
| 994 | maxi=new(number_comb,float) |
---|
[154] | 995 | end if |
---|
[190] | 996 | |
---|
[154] | 997 | wks=gsn_open_wks(format_out,file_out) |
---|
| 998 | gsn_define_colormap(wks,"rainbow+white") |
---|
[161] | 999 | |
---|
[154] | 1000 | ; *************************************************** |
---|
| 1001 | ; set up minimum and maximum height |
---|
[175] | 1002 | ; *************************************************** |
---|
[154] | 1003 | |
---|
[218] | 1004 | if (log_z .EQ. 1)then |
---|
[190] | 1005 | if (min_z .EQ. -1)then |
---|
[175] | 1006 | if (isvar("z_u"))then |
---|
| 1007 | min_z=z_u(1) |
---|
| 1008 | else |
---|
| 1009 | min_z=z_w(1) |
---|
[190] | 1010 | end if |
---|
[175] | 1011 | else |
---|
[190] | 1012 | if (isvar("z_w"))then |
---|
| 1013 | if (min_z .GE. max(z_w) ) then |
---|
[175] | 1014 | print(" ") |
---|
[190] | 1015 | print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_w)+")") |
---|
[175] | 1016 | print(" ") |
---|
| 1017 | exit |
---|
[190] | 1018 | end if |
---|
| 1019 | else |
---|
| 1020 | if (min_z .GE. max(z_u) ) then |
---|
| 1021 | print(" ") |
---|
| 1022 | print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_u)+")") |
---|
| 1023 | print(" ") |
---|
| 1024 | exit |
---|
| 1025 | end if |
---|
| 1026 | end if |
---|
| 1027 | if (isvar("z_u"))then |
---|
| 1028 | if (min_z .LT. z_u(1) ) then |
---|
| 1029 | print(" ") |
---|
| 1030 | print("Begin height 'min_z' at least at level k=1 (="+z_u(1)+"m) due to the logarithmic scale of the y-axis") |
---|
| 1031 | print(" ") |
---|
| 1032 | exit |
---|
[175] | 1033 | end if |
---|
[190] | 1034 | else |
---|
| 1035 | if (min_z .LT. z_w(1) ) then |
---|
[175] | 1036 | print(" ") |
---|
[190] | 1037 | print("Begin height 'min_z' at least at level k=1 (="+z_w(1)+"m) due to the logarithmic scale of the y-axis") |
---|
[175] | 1038 | print(" ") |
---|
| 1039 | exit |
---|
[190] | 1040 | end if |
---|
[175] | 1041 | end if |
---|
[190] | 1042 | end if |
---|
| 1043 | else |
---|
| 1044 | if (isvar("z_u"))then |
---|
| 1045 | if (min_z .EQ. -1)then |
---|
| 1046 | min_z=z_u(0) |
---|
| 1047 | end if |
---|
[175] | 1048 | else |
---|
[190] | 1049 | if (min_z .EQ. -1)then |
---|
| 1050 | min_z=z_w(0) |
---|
| 1051 | end if |
---|
| 1052 | end if |
---|
| 1053 | if (isvar("z_w"))then |
---|
| 1054 | if (min_z .GE. max(z_w) ) then |
---|
[175] | 1055 | print(" ") |
---|
[190] | 1056 | print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_w)+")") |
---|
[175] | 1057 | print(" ") |
---|
| 1058 | exit |
---|
| 1059 | end if |
---|
[190] | 1060 | else |
---|
| 1061 | if (min_z .EQ. -1)then |
---|
| 1062 | min_z=z_u(0) |
---|
[175] | 1063 | end if |
---|
[190] | 1064 | if (min_z .GE. max(z_u) ) then |
---|
[154] | 1065 | print(" ") |
---|
[190] | 1066 | print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_u)+")") |
---|
[154] | 1067 | print(" ") |
---|
| 1068 | exit |
---|
| 1069 | end if |
---|
| 1070 | end if |
---|
[190] | 1071 | end if |
---|
| 1072 | |
---|
| 1073 | if (isvar("z_w"))then |
---|
| 1074 | if (max_z .EQ. -1)then |
---|
| 1075 | max_z=max(z_w) |
---|
| 1076 | end if |
---|
[154] | 1077 | else |
---|
[190] | 1078 | if (max_z .EQ. -1)then |
---|
| 1079 | max_z=max(z_u) |
---|
| 1080 | end if |
---|
| 1081 | end if |
---|
| 1082 | |
---|
| 1083 | if (isvar("z_w"))then |
---|
| 1084 | if (max_z .GT. max(z_w) ) then |
---|
[154] | 1085 | print(" ") |
---|
[190] | 1086 | print("Maximum of height ('max_z'="+max_z+") is greater than available heights (="+max(z_w)+")") |
---|
[154] | 1087 | print(" ") |
---|
| 1088 | exit |
---|
| 1089 | end if |
---|
| 1090 | end if |
---|
| 1091 | |
---|
[218] | 1092 | min_z=min_z/norm_z |
---|
| 1093 | max_z=max_z/norm_z |
---|
[175] | 1094 | |
---|
[154] | 1095 | ; *************************************************** |
---|
| 1096 | ; read data and create plots |
---|
| 1097 | ; *************************************************** |
---|
| 1098 | |
---|
| 1099 | do ti = start_time_step, end_time_step |
---|
| 1100 | if( t_all(ti) .lt. 10^36) then |
---|
| 1101 | start_time_step = ti |
---|
| 1102 | break |
---|
| 1103 | end if |
---|
| 1104 | end do |
---|
[175] | 1105 | |
---|
[218] | 1106 | if (log_z .EQ. 1) then |
---|
[175] | 1107 | data = new((/dim,(end_time_step-start_time_step)+1,dimz-1/),float) |
---|
| 1108 | data_0 = new((/(end_time_step-start_time_step)+1,dimz-1/),float) |
---|
| 1109 | data_0 = 0.1 |
---|
| 1110 | t = new((/(end_time_step-start_time_step)+1,dimz-1/),float) |
---|
| 1111 | t = 0.0 |
---|
| 1112 | unit = new(dim,string) |
---|
| 1113 | if (isvar("z_u"))then |
---|
| 1114 | if (typeof(z_u) .EQ. "double")then |
---|
| 1115 | z_v = new((/dim,dimz/),double) |
---|
| 1116 | z_ = new((/dim,dimz-1/),double) |
---|
| 1117 | else |
---|
| 1118 | if (typeof(z_u) .EQ. "float")then |
---|
| 1119 | z_v = new((/dim,dimz/),float) |
---|
| 1120 | z_ = new((/dim,dimz-1/),float) |
---|
| 1121 | end if |
---|
| 1122 | end if |
---|
| 1123 | else |
---|
| 1124 | if (isvar("z_w"))then |
---|
| 1125 | if (typeof(z_w) .EQ. "double")then |
---|
| 1126 | z_v = new((/dim,dimz/),double) |
---|
| 1127 | z_ = new((/dim,dimz-1/),double) |
---|
| 1128 | else |
---|
| 1129 | if (typeof(z_w) .EQ. "float")then |
---|
| 1130 | z_v = new((/dim,dimz/),float) |
---|
| 1131 | z_ = new((/dim,dimz-1/),float) |
---|
| 1132 | end if |
---|
| 1133 | end if |
---|
| 1134 | end if |
---|
| 1135 | end if |
---|
| 1136 | else |
---|
| 1137 | data = new((/dim,(end_time_step-start_time_step)+1,dimz/),float) |
---|
| 1138 | data_0 = new((/(end_time_step-start_time_step)+1,dimz/),float) |
---|
| 1139 | data_0 = 0.0 |
---|
| 1140 | t = new((/(end_time_step-start_time_step)+1,dimz/),float) |
---|
| 1141 | t = 0.0 |
---|
| 1142 | unit = new(dim,string) |
---|
| 1143 | if (isvar("z_u"))then |
---|
| 1144 | if (typeof(z_u) .EQ. "double")then |
---|
| 1145 | z_v = new((/dim,dimz/),double) |
---|
| 1146 | z_ = new((/dim,dimz/),double) |
---|
| 1147 | else |
---|
| 1148 | if (typeof(z_u) .EQ. "float")then |
---|
| 1149 | z_v = new((/dim,dimz/),float) |
---|
| 1150 | z_ = new((/dim,dimz/),float) |
---|
| 1151 | end if |
---|
| 1152 | end if |
---|
| 1153 | else |
---|
| 1154 | if (isvar("z_w"))then |
---|
| 1155 | if (typeof(z_w) .EQ. "double")then |
---|
| 1156 | z_v = new((/dim,dimz/),double) |
---|
| 1157 | z_ = new((/dim,dimz/),double) |
---|
| 1158 | else |
---|
| 1159 | if (typeof(z_w) .EQ. "float")then |
---|
| 1160 | z_v = new((/dim,dimz/),float) |
---|
| 1161 | z_ = new((/dim,dimz/),float) |
---|
| 1162 | end if |
---|
| 1163 | end if |
---|
| 1164 | end if |
---|
| 1165 | end if |
---|
| 1166 | end if |
---|
[157] | 1167 | |
---|
[175] | 1168 | end if |
---|
| 1169 | ;------------------------------------------------------ above steps only for first file |
---|
| 1170 | |
---|
| 1171 | ; *************************************************** |
---|
| 1172 | ; indicate plot number |
---|
| 1173 | ; *************************************************** |
---|
| 1174 | |
---|
| 1175 | if (combine .EQ. 1) then |
---|
| 1176 | n = 1 |
---|
| 1177 | else |
---|
| 1178 | n = 0 |
---|
| 1179 | end if |
---|
| 1180 | |
---|
[161] | 1181 | if (over .EQ. 1) then |
---|
| 1182 | plot_u = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1183 | miniu = 1.E27 |
---|
| 1184 | maxiu =-1.E27 |
---|
| 1185 | plot_v = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1186 | miniv = 1.E27 |
---|
| 1187 | maxiv =-1.E27 |
---|
| 1188 | plot_w = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1189 | miniw = 1.E27 |
---|
| 1190 | maxiw =-1.E27 |
---|
| 1191 | plot_pt = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1192 | minipt = 1.E27 |
---|
| 1193 | maxipt =-1.E27 |
---|
| 1194 | plot_vpt = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1195 | minivpt = 1.E27 |
---|
| 1196 | maxivpt =-1.E27 |
---|
| 1197 | plot_lpt = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1198 | minilpt = 1.E27 |
---|
| 1199 | maxilpt =-1.E27 |
---|
| 1200 | plot_q = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1201 | miniq = 1.E27 |
---|
| 1202 | maxiq =-1.E27 |
---|
| 1203 | plot_qv = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1204 | miniqv = 1.E27 |
---|
| 1205 | maxiqv =-1.E27 |
---|
| 1206 | plot_ql = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1207 | miniql = 1.E27 |
---|
| 1208 | maxiql =-1.E27 |
---|
| 1209 | plot_rho = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1210 | plot_s = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1211 | plot_sa = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1212 | plot_e = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1213 | minie = 1.E27 |
---|
| 1214 | maxie =-1.E27 |
---|
| 1215 | plot_es = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1216 | minie = 1.E27 |
---|
| 1217 | maxie =-1.E27 |
---|
| 1218 | plot_km = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1219 | minie = 1.E27 |
---|
| 1220 | maxie =-1.E27 |
---|
| 1221 | plot_kh = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1222 | minie = 1.E27 |
---|
| 1223 | maxie =-1.E27 |
---|
| 1224 | plot_l = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1225 | plot_wpup = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1226 | miniwpup = 1.E27 |
---|
| 1227 | maxiwpup =-1.E27 |
---|
| 1228 | plot_wsus = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1229 | miniwsus = 1.E27 |
---|
| 1230 | maxiwsus =-1.E27 |
---|
| 1231 | plot_wu = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1232 | miniwu = 1.E27 |
---|
| 1233 | maxiwu =-1.E27 |
---|
| 1234 | plot_wpvp = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1235 | miniwpvp = 1.E27 |
---|
| 1236 | maxiwpvp =-1.E27 |
---|
| 1237 | plot_wsvs = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1238 | miniwsvs = 1.E27 |
---|
| 1239 | maxiwsvs =-1.E27 |
---|
| 1240 | plot_wv = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1241 | miniwv = 1.E27 |
---|
| 1242 | maxiwv =-1.E27 |
---|
| 1243 | plot_wpptp = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1244 | miniwpptp = 1.E27 |
---|
| 1245 | maxiwpptp =-1.E27 |
---|
| 1246 | plot_wspts = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1247 | miniwspts = 1.E27 |
---|
| 1248 | maxiwspts =-1.E27 |
---|
| 1249 | plot_wpt = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1250 | miniwpt = 1.E27 |
---|
| 1251 | maxiwpt =-1.E27 |
---|
| 1252 | plot_wsptsBC = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1253 | miniwsptsBC = 1.E27 |
---|
| 1254 | maxiwsptsBC =-1.E27 |
---|
| 1255 | plot_wptBC = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1256 | miniwptBC = 1.E27 |
---|
| 1257 | maxiwptBC =-1.E27 |
---|
| 1258 | plot_wpvptp = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1259 | miniwpvptp = 1.E27 |
---|
| 1260 | maxiwpvptp =-1.E27 |
---|
| 1261 | plot_wsvpts = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1262 | miniwsvpts = 1.E27 |
---|
| 1263 | maxiewsvpts=-1.E27 |
---|
| 1264 | plot_wvpt = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1265 | miniwvpt = 1.E27 |
---|
| 1266 | maxiwvpt =-1.E27 |
---|
| 1267 | plot_wpqp = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1268 | miniwpqp = 1.E27 |
---|
| 1269 | maxiwpqp =-1.E27 |
---|
| 1270 | plot_wsqs = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1271 | miniwsqs = 1.E27 |
---|
| 1272 | maxiwsqs =-1.E27 |
---|
| 1273 | plot_wq = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1274 | miniwq = 1.E27 |
---|
| 1275 | maxiwq =-1.E27 |
---|
| 1276 | plot_wpqvp = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1277 | miniwpqvp = 1.E27 |
---|
| 1278 | maxiwpqvp =-1.E27 |
---|
| 1279 | plot_wsqvs = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1280 | miniwsqvs = 1.E27 |
---|
| 1281 | maxiwsqvs =-1.E27 |
---|
| 1282 | plot_wqv = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1283 | miniwqv = 1.E27 |
---|
| 1284 | maxiwqv =-1.E27 |
---|
| 1285 | plot_wpsp = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1286 | miniwpsp = 1.E27 |
---|
| 1287 | maxiwpsp =-1.E27 |
---|
| 1288 | plot_wsss = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1289 | miniwsss = 1.E27 |
---|
| 1290 | maxiwsss =-1.E27 |
---|
| 1291 | plot_ws = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1292 | miniws = 1.E27 |
---|
| 1293 | maxiws =-1.E27 |
---|
| 1294 | plot_wpsap = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1295 | miniwpsap = 1.E27 |
---|
| 1296 | maxiwpsap =-1.E27 |
---|
| 1297 | plot_wssas = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1298 | miniwssas = 1.E27 |
---|
| 1299 | maxiwssas =-1.E27 |
---|
| 1300 | plot_wsa = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1301 | miniwsa = 1.E27 |
---|
| 1302 | maxiwsa =-1.E27 |
---|
| 1303 | plot_wses = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1304 | plot_us2 = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1305 | minius2 = 1.E27 |
---|
| 1306 | maxius2 =-1.E27 |
---|
| 1307 | plot_vs2 = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1308 | minivs2 = 1.E27 |
---|
| 1309 | maxivs2 =-1.E27 |
---|
| 1310 | plot_ws2 = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1311 | miniws2 = 1.E27 |
---|
| 1312 | maxiws2 =-1.E27 |
---|
| 1313 | plot_pts2 = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1314 | plot_ws3 = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1315 | plot_Sw = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1316 | plot_ws2pts = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1317 | plot_wspts2 = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1318 | plot_wsususodz = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1319 | miniwsususodz = 1.E27 |
---|
| 1320 | maxiwsususodz =-1.E27 |
---|
| 1321 | plot_wspsodz = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1322 | miniwspsodz = 1.E27 |
---|
| 1323 | maxiwspsodz =-1.E27 |
---|
| 1324 | plot_wpeodz = gsn_csm_xy(wks,t,data_0(:,:),res) |
---|
| 1325 | miniwpeodz = 1.E27 |
---|
| 1326 | maxiwpeodz =-1.E27 |
---|
| 1327 | end if |
---|
[218] | 1328 | |
---|
| 1329 | if (prof3d .EQ. 1)then |
---|
| 1330 | |
---|
| 1331 | if (end_x .EQ. -1) then |
---|
| 1332 | end_x=dimx-2 |
---|
| 1333 | end if |
---|
| 1334 | if (end_y .EQ. -1)then |
---|
| 1335 | end_y=dimy-2 |
---|
| 1336 | end if |
---|
| 1337 | if (start_x .LT. 0)then |
---|
| 1338 | print(" ") |
---|
| 1339 | print("'start_x' is lower than 0 and set to 0") |
---|
| 1340 | print(" ") |
---|
| 1341 | start_x=0 |
---|
| 1342 | end if |
---|
| 1343 | if (start_x .GT. dimx-1)then |
---|
| 1344 | print(" ") |
---|
| 1345 | print("'start_x' is greater than available x-range and set to maximum of x-range (excluding ghostpoint)") |
---|
| 1346 | print(" ") |
---|
| 1347 | start_x=dimx-2 |
---|
| 1348 | end if |
---|
| 1349 | if (end_x .EQ. dimx-1)then |
---|
| 1350 | print(" ") |
---|
| 1351 | print("'end_x' = "+end_x+" and includes the ghostpoint") |
---|
| 1352 | print(" ") |
---|
| 1353 | end if |
---|
| 1354 | if (end_x .GT. dimx-1)then |
---|
| 1355 | print(" ") |
---|
| 1356 | print("'end_x' = "+end_x+" is greater than available x-range and set to maximum of x-range (excluding ghostpoint)") |
---|
| 1357 | print(" ") |
---|
| 1358 | end_x=dimx-2 |
---|
| 1359 | end if |
---|
| 1360 | if (end_x .LT. start_x)then |
---|
| 1361 | print(" ") |
---|
| 1362 | print("'end_x' = "+end_x+" is lower than 'start_x' = "+start_x+" and set to maximum of x-range (excluding ghostpoint)") |
---|
| 1363 | print(" ") |
---|
| 1364 | end_x=dimx-2 |
---|
| 1365 | end if |
---|
| 1366 | if (start_y .LT. 0)then |
---|
| 1367 | print(" ") |
---|
| 1368 | print("'start_y' is lower than 0 and set to 0") |
---|
| 1369 | print(" ") |
---|
| 1370 | start_y=0 |
---|
| 1371 | end if |
---|
| 1372 | if (start_y .GT. dimy-1)then |
---|
| 1373 | print(" ") |
---|
| 1374 | print("'start_y' is greater than available y-range and set to maximum of y-range (excluding ghostpoint)") |
---|
| 1375 | print(" ") |
---|
| 1376 | start_x=dimy-2 |
---|
| 1377 | end if |
---|
| 1378 | if (end_y .EQ. dimy-1)then |
---|
| 1379 | print(" ") |
---|
| 1380 | print("'end_y' = "+end_y+" and includes the ghostpoint") |
---|
| 1381 | print(" ") |
---|
| 1382 | end if |
---|
| 1383 | if (end_y .GT. dimy-1)then |
---|
| 1384 | print(" ") |
---|
| 1385 | print("'end_y' = "+end_y+" is greater than available y-range and set to maximum of y-range (excluding ghostpoint)") |
---|
| 1386 | print(" ") |
---|
| 1387 | end_x=dimy-2 |
---|
| 1388 | end if |
---|
| 1389 | if (end_y .LT. start_y)then |
---|
| 1390 | print(" ") |
---|
| 1391 | print("'end_y' = "+end_y+" is lower than 'start_y' = "+start_y+" and set to maximum of y-range (excluding ghostpoint)") |
---|
| 1392 | print(" ") |
---|
| 1393 | end_y=dimy-2 |
---|
| 1394 | end if |
---|
| 1395 | |
---|
| 1396 | end if |
---|
| 1397 | |
---|
[161] | 1398 | n_o=0 |
---|
[162] | 1399 | count_var=0 |
---|
[250] | 1400 | |
---|
[219] | 1401 | res@xyDashPattern = 1*nof |
---|
[250] | 1402 | |
---|
[161] | 1403 | do varn = 0,dim-1 |
---|
[174] | 1404 | |
---|
| 1405 | check = True |
---|
[161] | 1406 | |
---|
[174] | 1407 | if (prof3d .EQ. 0) then |
---|
| 1408 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then |
---|
| 1409 | check = False |
---|
| 1410 | end if |
---|
[154] | 1411 | else |
---|
[174] | 1412 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "zusi") .OR. isStrSubset( vNam(varn), "zwwi") .OR. isStrSubset( vNam(varn), "x") .OR. isStrSubset( vNam(varn), "xu") .OR. isStrSubset( vNam(varn), "y") .OR. isStrSubset( vNam(varn), "yv") .OR. isStrSubset( vNam(varn), "zu_3d") .OR. isStrSubset( vNam(varn), "zw_3d")) then |
---|
| 1413 | check = False |
---|
| 1414 | end if |
---|
| 1415 | end if |
---|
| 1416 | |
---|
[190] | 1417 | if (var .NE. "all") then |
---|
[174] | 1418 | check = isStrSubset( var,","+vNam(varn)+"," ) |
---|
[154] | 1419 | end if |
---|
[161] | 1420 | |
---|
| 1421 | if (combine .EQ. 1) then |
---|
| 1422 | com=isStrSubset(c_var,","+vNam(varn)+"," ) |
---|
[175] | 1423 | if (com) then |
---|
[174] | 1424 | if (prof3d .EQ. 0) then |
---|
[236] | 1425 | if (t_null)then |
---|
| 1426 | temp = f[:]->$vNam(varn)$(1:,:) |
---|
| 1427 | else |
---|
| 1428 | temp = f[:]->$vNam(varn)$ |
---|
| 1429 | end if |
---|
[218] | 1430 | temp_att = f_att->$vNam(varn)$ |
---|
| 1431 | if (log_z .EQ. 1) then |
---|
[175] | 1432 | data(varn,:,:) = temp(start_time_step:end_time_step,1:dimz-1) |
---|
| 1433 | else |
---|
| 1434 | data(varn,:,:) = temp(start_time_step:end_time_step,0:dimz-1) |
---|
| 1435 | end if |
---|
[174] | 1436 | else |
---|
[218] | 1437 | if (log_z .EQ. 1) then |
---|
[175] | 1438 | do i=1,dimz-1 |
---|
| 1439 | do j=start_time_step,end_time_step |
---|
[218] | 1440 | temp= f[:]->$vNam(varn)$ |
---|
| 1441 | temp_att = f_att->$vNam(varn)$ |
---|
| 1442 | data_temp = temp(j,i,start_y:end_y,start_x:end_x) |
---|
| 1443 | data(varn,j-start_time_step,i-1) = dim_avg_Wrap(dim_avg_Wrap(data_temp)) |
---|
[175] | 1444 | end do |
---|
[174] | 1445 | end do |
---|
[175] | 1446 | else |
---|
| 1447 | do i=0,dimz-1 |
---|
| 1448 | do j=start_time_step,end_time_step |
---|
[218] | 1449 | temp= f[:]->$vNam(varn)$ |
---|
| 1450 | temp_att = f_att->$vNam(varn)$ |
---|
| 1451 | data_temp = temp(j,i,start_y:end_y,start_x:end_x) |
---|
| 1452 | data(varn,j-start_time_step,i) = dim_avg_Wrap(dim_avg_Wrap(data_temp)) |
---|
[175] | 1453 | end do |
---|
| 1454 | end do |
---|
| 1455 | end if |
---|
[174] | 1456 | print(" ") |
---|
| 1457 | print("Variable for combine '"+vNam(varn)+"' is read") |
---|
| 1458 | print(" ") |
---|
| 1459 | end if |
---|
[218] | 1460 | unit(varn) = temp_att@units |
---|
[161] | 1461 | if (n_o .GT. number_comb-1) then |
---|
| 1462 | print(" ") |
---|
[218] | 1463 | print("Set 'number_comb' to the number of overlaying variables ('c_var' = "+c_var+")") |
---|
[161] | 1464 | print(" ") |
---|
| 1465 | exit |
---|
| 1466 | end if |
---|
| 1467 | mini(n_o)=min(data(varn,:,:)) |
---|
| 1468 | maxi(n_o)=max(data(varn,:,:)) |
---|
| 1469 | n_o=n_o+1 |
---|
| 1470 | end if |
---|
| 1471 | end if |
---|
| 1472 | |
---|
| 1473 | if(check) then |
---|
[175] | 1474 | if (isStrSubset(vNam(varn),"_0" ))then |
---|
| 1475 | print(" ") |
---|
| 1476 | print("If you have Outputs of statistic regions you cannot overlay variables; 'over' is set to 0") |
---|
| 1477 | print(" ") |
---|
| 1478 | over = 0 |
---|
| 1479 | end if |
---|
| 1480 | |
---|
[162] | 1481 | count_var=count_var+1 |
---|
[174] | 1482 | |
---|
| 1483 | if (prof3d .EQ. 0) then |
---|
[236] | 1484 | if (t_null)then |
---|
| 1485 | temp = f[:]->$vNam(varn)$(1:,:) |
---|
| 1486 | else |
---|
| 1487 | temp = f[:]->$vNam(varn)$ |
---|
| 1488 | end if |
---|
[218] | 1489 | temp_att = f_att->$vNam(varn)$ |
---|
[174] | 1490 | else |
---|
[218] | 1491 | if (log_z .EQ. 1) then |
---|
[175] | 1492 | do i=1,dimz-1 |
---|
| 1493 | do j=start_time_step,end_time_step |
---|
[218] | 1494 | temp= f[:]->$vNam(varn)$(j,i,start_y:end_y,start_x:end_x) |
---|
| 1495 | temp_att = f_att->$vNam(varn)$ |
---|
| 1496 | data_temp = temp(j,i,start_y:end_y,start_x:end_x) |
---|
| 1497 | data(varn,j-start_time_step,i-1) = dim_avg_Wrap(dim_avg_Wrap(data_temp)) |
---|
[175] | 1498 | end do |
---|
[174] | 1499 | end do |
---|
[175] | 1500 | else |
---|
| 1501 | do i=0,dimz-1 |
---|
| 1502 | do j=start_time_step,end_time_step |
---|
[218] | 1503 | temp= f[:]->$vNam(varn)$;(j,i,start_y:end_y,start_x:end_x) |
---|
| 1504 | temp_att = f_att->$vNam(varn)$ |
---|
| 1505 | data_temp = temp(j,i,start_y:end_y,start_x:end_x) |
---|
| 1506 | data_temp!0 = "t" |
---|
| 1507 | data_temp!1 = "z" |
---|
| 1508 | data(varn,j-start_time_step,i) = dim_avg_Wrap(dim_avg_Wrap(data_temp)) |
---|
[175] | 1509 | end do |
---|
| 1510 | end do |
---|
| 1511 | end if |
---|
[174] | 1512 | print(" ") |
---|
| 1513 | print("Variable '"+vNam(varn)+"' is read") |
---|
| 1514 | print(" ") |
---|
[218] | 1515 | unit(varn) = temp_att@units |
---|
| 1516 | a=getvardims(temp_att) |
---|
[174] | 1517 | b=dimsizes(a) |
---|
| 1518 | end if |
---|
[218] | 1519 | |
---|
[174] | 1520 | if (prof3d .EQ. 0) then |
---|
[218] | 1521 | if (log_z .EQ. 1) then |
---|
| 1522 | z = f_att->$vNam(varn+1)$(1:dimz-1) |
---|
| 1523 | unit(varn) = temp_att@units |
---|
[175] | 1524 | data(varn,:,:) = temp(start_time_step:end_time_step,1:dimz-1) |
---|
| 1525 | else |
---|
[218] | 1526 | z = f_att->$vNam(varn+1)$ |
---|
| 1527 | unit(varn) = temp_att@units |
---|
[175] | 1528 | data(varn,:,:) = temp(start_time_step:end_time_step,:) |
---|
| 1529 | end if |
---|
[174] | 1530 | else |
---|
[218] | 1531 | do i=0,b-1 |
---|
[175] | 1532 | if (isStrSubset( a(i),"zu_3d" ))then |
---|
[174] | 1533 | z_v(varn,:) = z_u |
---|
[218] | 1534 | if (log_z .EQ. 1) then |
---|
[175] | 1535 | z = z_v(varn,1:dimz-1) |
---|
| 1536 | else |
---|
| 1537 | z = z_v(varn,:) |
---|
| 1538 | end if |
---|
[174] | 1539 | else |
---|
[175] | 1540 | if (isStrSubset( a(i),"zw_3d" ))then |
---|
[174] | 1541 | z_v(varn,:) = z_w |
---|
[218] | 1542 | if (log_z .EQ. 1) then |
---|
[175] | 1543 | z = z_v(varn,1:dimz-1) |
---|
| 1544 | else |
---|
| 1545 | z = z_v(varn,:) |
---|
| 1546 | end if |
---|
[174] | 1547 | end if |
---|
| 1548 | end if |
---|
| 1549 | end do |
---|
| 1550 | end if |
---|
[236] | 1551 | |
---|
[175] | 1552 | if (nof .EQ. 0) then |
---|
[218] | 1553 | z_(n,:)=z/norm_z |
---|
[175] | 1554 | z = z_(n,:) |
---|
| 1555 | else |
---|
[218] | 1556 | z=z/norm_z |
---|
[175] | 1557 | end if |
---|
| 1558 | |
---|
[161] | 1559 | if (over .EQ. 0) then |
---|
| 1560 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1561 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1562 | res@gsnRightString = " " |
---|
[161] | 1563 | res@trYMinF = min_z |
---|
[162] | 1564 | res@trYMaxF = max_z |
---|
[190] | 1565 | if (xs .EQ. -1) then |
---|
| 1566 | res@trXMinF = min(data(varn,:,:)) |
---|
[162] | 1567 | else |
---|
| 1568 | res@trXMinF = xs |
---|
| 1569 | end if |
---|
[190] | 1570 | if (xe .EQ. -1) then |
---|
| 1571 | res@trXMaxF = max(data(varn,:,:)) |
---|
[162] | 1572 | else |
---|
| 1573 | res@trXMaxF = xe |
---|
[175] | 1574 | end if |
---|
[161] | 1575 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[250] | 1576 | end if |
---|
| 1577 | |
---|
[161] | 1578 | if (vNam(varn) .EQ. "u") then |
---|
| 1579 | miniu=min(data(varn,:,:)) |
---|
| 1580 | maxiu=max(data(varn,:,:)) |
---|
| 1581 | if (over .EQ. 1) then |
---|
| 1582 | res@xyDashPattern = 0 |
---|
[175] | 1583 | plot_u = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1584 | else |
---|
| 1585 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1586 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1587 | res@gsnRightString = " " |
---|
[190] | 1588 | if (xs .EQ. -1) then |
---|
| 1589 | res@trXMinF = miniu |
---|
[162] | 1590 | else |
---|
| 1591 | res@trXMinF = xs |
---|
| 1592 | end if |
---|
[190] | 1593 | if (xe .EQ. -1) then |
---|
| 1594 | res@trXMaxF = maxiu |
---|
[162] | 1595 | else |
---|
| 1596 | res@trXMaxF = xe |
---|
| 1597 | end if |
---|
[175] | 1598 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1599 | end if |
---|
| 1600 | end if |
---|
| 1601 | if (vNam(varn) .EQ. "v") then |
---|
| 1602 | miniv=min(data(varn,:,:)) |
---|
| 1603 | maxiv=max(data(varn,:,:)) |
---|
| 1604 | if (over .EQ. 1) then |
---|
[250] | 1605 | res@xyMonoDashPattern = True |
---|
[161] | 1606 | res@xyDashPattern = 1 |
---|
[175] | 1607 | plot_v = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1608 | else |
---|
| 1609 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1610 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1611 | res@gsnRightString = " " |
---|
[190] | 1612 | if (xs .EQ. -1) then |
---|
| 1613 | res@trXMinF = miniv |
---|
[162] | 1614 | else |
---|
| 1615 | res@trXMinF = xs |
---|
| 1616 | end if |
---|
[190] | 1617 | if (xe .EQ. -1) then |
---|
| 1618 | res@trXMaxF = maxiv |
---|
[162] | 1619 | else |
---|
| 1620 | res@trXMaxF = xe |
---|
| 1621 | end if |
---|
[175] | 1622 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1623 | end if |
---|
| 1624 | end if |
---|
| 1625 | if (vNam(varn) .EQ. "w") then |
---|
| 1626 | miniw=min(data(varn,:,:)) |
---|
| 1627 | maxiw=max(data(varn,:,:)) |
---|
| 1628 | if (over .EQ. 1) then |
---|
[250] | 1629 | res@xyDashPattern = 2 |
---|
[175] | 1630 | plot_w = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1631 | else |
---|
| 1632 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1633 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1634 | res@gsnRightString = " " |
---|
[190] | 1635 | if (xs .EQ. -1) then |
---|
| 1636 | res@trXMinF = miniw |
---|
[162] | 1637 | else |
---|
| 1638 | res@trXMinF = xs |
---|
| 1639 | end if |
---|
[190] | 1640 | if (xe .EQ. -1) then |
---|
| 1641 | res@trXMaxF = maxiw |
---|
[162] | 1642 | else |
---|
| 1643 | res@trXMaxF = xe |
---|
| 1644 | end if |
---|
[175] | 1645 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1646 | end if |
---|
| 1647 | end if |
---|
[154] | 1648 | |
---|
[161] | 1649 | if (vNam(varn) .EQ. "pt") then |
---|
| 1650 | minipt=min(data(varn,:,:)) |
---|
| 1651 | maxipt=max(data(varn,:,:)) |
---|
| 1652 | if (over .EQ. 1) then |
---|
| 1653 | res@xyDashPattern = 0 |
---|
[175] | 1654 | plot_pt = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1655 | else |
---|
| 1656 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1657 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1658 | res@gsnRightString = " " |
---|
[190] | 1659 | if (xs .EQ. -1) then |
---|
| 1660 | res@trXMinF = minipt |
---|
[162] | 1661 | else |
---|
| 1662 | res@trXMinF = xs |
---|
| 1663 | end if |
---|
[190] | 1664 | if (xe .EQ. -1) then |
---|
| 1665 | res@trXMaxF = maxipt |
---|
[162] | 1666 | else |
---|
| 1667 | res@trXMaxF = xe |
---|
| 1668 | end if |
---|
[175] | 1669 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1670 | end if |
---|
| 1671 | end if |
---|
| 1672 | if (vNam(varn) .EQ. "vpt") then |
---|
| 1673 | minivpt=min(data(varn,:,:)) |
---|
| 1674 | maxivpt=max(data(varn,:,:)) |
---|
| 1675 | if (over .EQ. 1) then |
---|
| 1676 | res@xyDashPattern = 1 |
---|
[175] | 1677 | plot_vpt = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1678 | else |
---|
| 1679 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1680 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1681 | res@gsnRightString = " " |
---|
[190] | 1682 | if (xs .EQ. -1) then |
---|
| 1683 | res@trXMinF = minivpt |
---|
[162] | 1684 | else |
---|
| 1685 | res@trXMinF = xs |
---|
| 1686 | end if |
---|
[190] | 1687 | if (xe .EQ. -1) then |
---|
| 1688 | res@trXMaxF = maxivpt |
---|
[162] | 1689 | else |
---|
| 1690 | res@trXMaxF = xe |
---|
[190] | 1691 | end if |
---|
[175] | 1692 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1693 | end if |
---|
| 1694 | end if |
---|
| 1695 | if (vNam(varn) .EQ. "lpt") then |
---|
| 1696 | minilpt=min(data(varn,:,:)) |
---|
| 1697 | maxilpt=max(data(varn,:,:)) |
---|
| 1698 | if (over .EQ. 1) then |
---|
| 1699 | res@xyDashPattern = 2 |
---|
[175] | 1700 | plot_lpt = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1701 | else |
---|
| 1702 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1703 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1704 | res@gsnRightString = " " |
---|
[190] | 1705 | if (xs .EQ. -1) then |
---|
| 1706 | res@trXMinF = minilpt |
---|
[162] | 1707 | else |
---|
| 1708 | res@trXMinF = xs |
---|
| 1709 | end if |
---|
[190] | 1710 | if (xe .EQ. -1) then |
---|
| 1711 | res@trXMaxF = maxilpt |
---|
[162] | 1712 | else |
---|
| 1713 | res@trXMaxF = xe |
---|
| 1714 | end if |
---|
[175] | 1715 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1716 | end if |
---|
| 1717 | end if |
---|
| 1718 | |
---|
| 1719 | if (vNam(varn) .EQ. "q") then |
---|
| 1720 | miniq=min(data(varn,:,:)) |
---|
| 1721 | maxiq=max(data(varn,:,:)) |
---|
| 1722 | if (over .EQ. 1) then |
---|
| 1723 | res@xyDashPattern = 0 |
---|
[175] | 1724 | plot_q = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1725 | else |
---|
| 1726 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1727 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1728 | res@gsnRightString = " " |
---|
[190] | 1729 | if (xs .EQ. -1) then |
---|
| 1730 | res@trXMinF = minilq |
---|
[162] | 1731 | else |
---|
| 1732 | res@trXMinF = xs |
---|
| 1733 | end if |
---|
[190] | 1734 | if (xe .EQ. -1) then |
---|
| 1735 | res@trXMaxF = maxilq |
---|
[162] | 1736 | else |
---|
| 1737 | res@trXMaxF = xe |
---|
| 1738 | end if |
---|
[175] | 1739 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1740 | end if |
---|
| 1741 | end if |
---|
| 1742 | if (vNam(varn) .EQ. "qv") then |
---|
| 1743 | miniqv=min(data(varn,:,:)) |
---|
| 1744 | maxiqv=max(data(varn,:,:)) |
---|
| 1745 | if (over .EQ. 1) then |
---|
| 1746 | res@xyDashPattern = 1 |
---|
[175] | 1747 | plot_qv = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1748 | else |
---|
| 1749 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1750 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1751 | res@gsnRightString = " " |
---|
[190] | 1752 | if (xs .EQ. -1) then |
---|
| 1753 | res@trXMinF = minilqv |
---|
[162] | 1754 | else |
---|
| 1755 | res@trXMinF = xs |
---|
| 1756 | end if |
---|
[190] | 1757 | if (xe .EQ. -1) then |
---|
| 1758 | res@trXMaxF = maxilqv |
---|
[162] | 1759 | else |
---|
| 1760 | res@trXMaxF = xe |
---|
| 1761 | end if |
---|
[175] | 1762 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1763 | end if |
---|
| 1764 | end if |
---|
| 1765 | if (vNam(varn) .EQ. "ql") then |
---|
| 1766 | miniql=min(data(varn,:,:)) |
---|
| 1767 | maxiql=max(data(varn,:,:)) |
---|
| 1768 | if (over .EQ. 1) then |
---|
| 1769 | res@xyDashPattern = 2 |
---|
[175] | 1770 | plot_ql = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1771 | else |
---|
| 1772 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1773 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1774 | res@gsnRightString = " " |
---|
[190] | 1775 | if (xs .EQ. -1) then |
---|
| 1776 | res@trXMinF = miniql |
---|
[162] | 1777 | else |
---|
| 1778 | res@trXMinF = xs |
---|
| 1779 | end if |
---|
[190] | 1780 | if (xe .EQ. -1) then |
---|
| 1781 | res@trXMaxF = maxiql |
---|
[162] | 1782 | else |
---|
| 1783 | res@trXMaxF = xe |
---|
| 1784 | end if |
---|
[175] | 1785 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1786 | end if |
---|
| 1787 | end if |
---|
| 1788 | |
---|
| 1789 | if (vNam(varn) .EQ. "e") then |
---|
| 1790 | minie=min(data(varn,:,:)) |
---|
| 1791 | maxie=max(data(varn,:,:)) |
---|
| 1792 | if (over .EQ. 1) then |
---|
| 1793 | res@xyDashPattern = 0 |
---|
[175] | 1794 | plot_e = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1795 | else |
---|
| 1796 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1797 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1798 | res@gsnRightString = " " |
---|
[190] | 1799 | if (xs .EQ. -1) then |
---|
| 1800 | res@trXMinF = minie |
---|
[162] | 1801 | else |
---|
| 1802 | res@trXMinF = xs |
---|
| 1803 | end if |
---|
[190] | 1804 | if (xe .EQ. -1) then |
---|
| 1805 | res@trXMaxF = maxie |
---|
[162] | 1806 | else |
---|
| 1807 | res@trXMaxF = xe |
---|
| 1808 | end if |
---|
[175] | 1809 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1810 | end if |
---|
| 1811 | end if |
---|
| 1812 | if (vNam(varn) .EQ. "es") then |
---|
| 1813 | minies=min(data(varn,:,:)) |
---|
| 1814 | maxies=max(data(varn,:,:)) |
---|
| 1815 | if (over .EQ. 1) then |
---|
| 1816 | res@xyDashPattern = 1 |
---|
[175] | 1817 | plot_es = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1818 | else |
---|
| 1819 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1820 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1821 | res@gsnRightString = " " |
---|
[190] | 1822 | if (xs .EQ. -1) then |
---|
| 1823 | res@trXMinF = minies |
---|
[162] | 1824 | else |
---|
| 1825 | res@trXMinF = xs |
---|
| 1826 | end if |
---|
[190] | 1827 | if (xe .EQ. -1) then |
---|
| 1828 | res@trXMaxF = maxies |
---|
[162] | 1829 | else |
---|
| 1830 | res@trXMaxF = xe |
---|
| 1831 | end if |
---|
[175] | 1832 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1833 | end if |
---|
| 1834 | end if |
---|
| 1835 | |
---|
| 1836 | if (vNam(varn) .EQ. "km") then |
---|
| 1837 | minikm=min(data(varn,:,:)) |
---|
| 1838 | maxikm=max(data(varn,:,:)) |
---|
| 1839 | if (over .EQ. 1) then |
---|
| 1840 | res@xyDashPattern = 0 |
---|
[175] | 1841 | plot_km = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1842 | else |
---|
| 1843 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1844 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1845 | res@gsnRightString = " " |
---|
[190] | 1846 | if (xs .EQ. -1) then |
---|
| 1847 | res@trXMinF = minikm |
---|
[162] | 1848 | else |
---|
| 1849 | res@trXMinF = xs |
---|
| 1850 | end if |
---|
[190] | 1851 | if (xe .EQ. -1) then |
---|
| 1852 | res@trXMaxF = maxikm |
---|
[162] | 1853 | else |
---|
| 1854 | res@trXMaxF = xe |
---|
| 1855 | end if |
---|
[175] | 1856 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1857 | end if |
---|
| 1858 | end if |
---|
| 1859 | if (vNam(varn) .EQ. "kh") then |
---|
| 1860 | minikh=min(data(varn,:,:)) |
---|
| 1861 | maxikh=max(data(varn,:,:)) |
---|
| 1862 | if (over .EQ. 1) then |
---|
| 1863 | res@xyDashPattern = 1 |
---|
[175] | 1864 | plot_kh = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1865 | else |
---|
| 1866 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1867 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1868 | res@gsnRightString = " " |
---|
[190] | 1869 | if (xs .EQ. -1) then |
---|
| 1870 | res@trXMinF = minikh |
---|
[162] | 1871 | else |
---|
| 1872 | res@trXMinF = xs |
---|
| 1873 | end if |
---|
[190] | 1874 | if (xe .EQ. -1) then |
---|
| 1875 | res@trXMaxF = maxikh |
---|
[162] | 1876 | else |
---|
| 1877 | res@trXMaxF = xe |
---|
| 1878 | end if |
---|
[175] | 1879 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1880 | end if |
---|
| 1881 | end if |
---|
| 1882 | |
---|
| 1883 | if (vNam(varn) .EQ. "wpup") then |
---|
| 1884 | miniwpup=min(data(varn,:,:)) |
---|
| 1885 | maxiwpup=max(data(varn,:,:)) |
---|
| 1886 | if (over .EQ. 1) then |
---|
| 1887 | res@xyDashPattern = 0 |
---|
[175] | 1888 | plot_wpup = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1889 | else |
---|
| 1890 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1891 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1892 | res@gsnRightString = " " |
---|
[190] | 1893 | if (xs .EQ. -1) then |
---|
| 1894 | res@trXMinF = miniwpup |
---|
[162] | 1895 | else |
---|
| 1896 | res@trXMinF = xs |
---|
| 1897 | end if |
---|
[190] | 1898 | if (xe .EQ. -1) then |
---|
| 1899 | res@trXMaxF = maxiwpup |
---|
[162] | 1900 | else |
---|
| 1901 | res@trXMaxF = xe |
---|
| 1902 | end if |
---|
[175] | 1903 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1904 | end if |
---|
| 1905 | end if |
---|
| 1906 | if (vNam(varn) .EQ. "wsus") then |
---|
| 1907 | miniwsus=min(data(varn,:,:)) |
---|
| 1908 | maxiwsus=max(data(varn,:,:)) |
---|
| 1909 | if (over .EQ. 1) then |
---|
| 1910 | res@xyDashPattern = 1 |
---|
[175] | 1911 | plot_wsus = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1912 | else |
---|
| 1913 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1914 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1915 | res@gsnRightString = " " |
---|
[190] | 1916 | if (xs .EQ. -1) then |
---|
| 1917 | res@trXMinF = miniwsus |
---|
[162] | 1918 | else |
---|
| 1919 | res@trXMinF = xs |
---|
| 1920 | end if |
---|
[190] | 1921 | if (xe .EQ. -1) then |
---|
| 1922 | res@trXMaxF = maxiwsus |
---|
[162] | 1923 | else |
---|
| 1924 | res@trXMaxF = xe |
---|
| 1925 | end if |
---|
[175] | 1926 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1927 | end if |
---|
| 1928 | end if |
---|
| 1929 | if (vNam(varn) .EQ. "wu") then |
---|
| 1930 | miniwu=min(data(varn,:,:)) |
---|
| 1931 | maxiwu=max(data(varn,:,:)) |
---|
| 1932 | if (over .EQ. 1) then |
---|
| 1933 | res@xyDashPattern = 2 |
---|
[175] | 1934 | plot_wu = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1935 | else |
---|
| 1936 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1937 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1938 | res@gsnRightString = " " |
---|
[190] | 1939 | if (xs .EQ. -1) then |
---|
| 1940 | res@trXMinF = miniwu |
---|
[162] | 1941 | else |
---|
| 1942 | res@trXMinF = xs |
---|
| 1943 | end if |
---|
[190] | 1944 | if (xe .EQ. -1) then |
---|
| 1945 | res@trXMaxF = maxiwu |
---|
[162] | 1946 | else |
---|
| 1947 | res@trXMaxF = xe |
---|
| 1948 | end if |
---|
[175] | 1949 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1950 | end if |
---|
| 1951 | end if |
---|
| 1952 | |
---|
| 1953 | if (vNam(varn) .EQ. "wpvp") then |
---|
| 1954 | miniwpvp=min(data(varn,:,:)) |
---|
| 1955 | maxiwpvp=max(data(varn,:,:)) |
---|
| 1956 | if (over .EQ. 1) then |
---|
| 1957 | res@xyDashPattern = 0 |
---|
[175] | 1958 | plot_wpvp = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1959 | else |
---|
| 1960 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1961 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1962 | res@gsnRightString = " " |
---|
[190] | 1963 | if (xs .EQ. -1) then |
---|
| 1964 | res@trXMinF = miniwpvp |
---|
[162] | 1965 | else |
---|
| 1966 | res@trXMinF = xs |
---|
| 1967 | end if |
---|
[190] | 1968 | if (xe .EQ. -1) then |
---|
| 1969 | res@trXMaxF = maxiwpvp |
---|
[162] | 1970 | else |
---|
| 1971 | res@trXMaxF = xe |
---|
| 1972 | end if |
---|
[175] | 1973 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1974 | end if |
---|
| 1975 | end if |
---|
| 1976 | if (vNam(varn) .EQ. "wsvs") then |
---|
| 1977 | miniwsvs=min(data(varn,:,:)) |
---|
| 1978 | maxiwsvs=max(data(varn,:,:)) |
---|
| 1979 | if (over .EQ. 1) then |
---|
| 1980 | res@xyDashPattern = 1 |
---|
[175] | 1981 | plot_wsvs = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1982 | else |
---|
| 1983 | res@gsnLeftString = vNam(varn) |
---|
[218] | 1984 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 1985 | res@gsnRightString = " " |
---|
[190] | 1986 | if (xs .EQ. -1) then |
---|
| 1987 | res@trXMinF = miniwsvs |
---|
[162] | 1988 | else |
---|
| 1989 | res@trXMinF = xs |
---|
| 1990 | end if |
---|
[190] | 1991 | if (xe .EQ. -1) then |
---|
| 1992 | res@trXMaxF = maxiwsvs |
---|
[162] | 1993 | else |
---|
| 1994 | res@trXMaxF = xe |
---|
| 1995 | end if |
---|
[175] | 1996 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 1997 | end if |
---|
| 1998 | end if |
---|
| 1999 | if (vNam(varn) .EQ. "wv") then |
---|
| 2000 | miniwv=min(data(varn,:,:)) |
---|
| 2001 | maxiwv=max(data(varn,:,:)) |
---|
| 2002 | if (over .EQ. 1) then |
---|
| 2003 | res@xyDashPattern = 2 |
---|
[175] | 2004 | plot_wv = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2005 | else |
---|
| 2006 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2007 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2008 | res@gsnRightString = " " |
---|
[190] | 2009 | if (xs .EQ. -1) then |
---|
| 2010 | res@trXMinF = miniwv |
---|
[162] | 2011 | else |
---|
| 2012 | res@trXMinF = xs |
---|
| 2013 | end if |
---|
[190] | 2014 | if (xe .EQ. -1) then |
---|
| 2015 | res@trXMaxF = maxiwv |
---|
[162] | 2016 | else |
---|
| 2017 | res@trXMaxF = xe |
---|
| 2018 | end if |
---|
[175] | 2019 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2020 | end if |
---|
| 2021 | end if |
---|
| 2022 | |
---|
| 2023 | if (vNam(varn) .EQ. "wpptp") then |
---|
| 2024 | miniwpptp=min(data(varn,:,:)) |
---|
| 2025 | maxiwpptp=max(data(varn,:,:)) |
---|
| 2026 | if (over .EQ. 1) then |
---|
| 2027 | res@xyDashPattern = 0 |
---|
[175] | 2028 | plot_wpptp = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2029 | else |
---|
| 2030 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2031 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2032 | res@gsnRightString = " " |
---|
[190] | 2033 | if (xs .EQ. -1) then |
---|
| 2034 | res@trXMinF = miniwpptp |
---|
[162] | 2035 | else |
---|
| 2036 | res@trXMinF = xs |
---|
| 2037 | end if |
---|
[190] | 2038 | if (xe .EQ. -1) then |
---|
| 2039 | res@trXMaxF = maxiwpptp |
---|
[162] | 2040 | else |
---|
| 2041 | res@trXMaxF = xe |
---|
| 2042 | end if |
---|
[175] | 2043 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2044 | end if |
---|
| 2045 | end if |
---|
| 2046 | if (vNam(varn) .EQ. "wspts") then |
---|
| 2047 | miniwspts=min(data(varn,:,:)) |
---|
| 2048 | maxiwspts=max(data(varn,:,:)) |
---|
| 2049 | if (over .EQ. 1) then |
---|
| 2050 | res@xyDashPattern = 1 |
---|
[175] | 2051 | plot_wspts = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2052 | else |
---|
| 2053 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2054 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2055 | res@gsnRightString = " " |
---|
[190] | 2056 | if (xs .EQ. -1) then |
---|
| 2057 | res@trXMinF = miniwspts |
---|
[162] | 2058 | else |
---|
| 2059 | res@trXMinF = xs |
---|
| 2060 | end if |
---|
[190] | 2061 | if (xe .EQ. -1) then |
---|
| 2062 | res@trXMaxF = maxiwspts |
---|
[162] | 2063 | else |
---|
| 2064 | res@trXMaxF = xe |
---|
| 2065 | end if |
---|
[175] | 2066 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2067 | end if |
---|
| 2068 | end if |
---|
| 2069 | if (vNam(varn) .EQ. "wpt") then |
---|
| 2070 | miniwpt=min(data(varn,:,:)) |
---|
| 2071 | maxiwpt=max(data(varn,:,:)) |
---|
| 2072 | if (over .EQ. 1) then |
---|
| 2073 | res@xyDashPattern = 2 |
---|
[175] | 2074 | plot_wpt = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2075 | else |
---|
| 2076 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2077 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2078 | res@gsnRightString = " " |
---|
[190] | 2079 | if (xs .EQ. -1) then |
---|
| 2080 | res@trXMinF = miniwpt |
---|
[162] | 2081 | else |
---|
| 2082 | res@trXMinF = xs |
---|
| 2083 | end if |
---|
[190] | 2084 | if (xe .EQ. -1) then |
---|
| 2085 | res@trXMaxF = maxiwpt |
---|
[162] | 2086 | else |
---|
| 2087 | res@trXMaxF = xe |
---|
| 2088 | end if |
---|
[175] | 2089 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2090 | end if |
---|
| 2091 | end if |
---|
| 2092 | |
---|
| 2093 | if (vNam(varn) .EQ. "wsptsBC") then |
---|
| 2094 | miniwsptsBC=min(data(varn,:,:)) |
---|
| 2095 | maxiwsptsBC=max(data(varn,:,:)) |
---|
| 2096 | if (over .EQ. 1) then |
---|
| 2097 | res@xyDashPattern = 0 |
---|
[175] | 2098 | plot_wsptsBC = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2099 | else |
---|
| 2100 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2101 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2102 | res@gsnRightString = " " |
---|
[190] | 2103 | if (xs .EQ. -1) then |
---|
| 2104 | res@trXMinF = miniwsptsBC |
---|
[162] | 2105 | else |
---|
| 2106 | res@trXMinF = xs |
---|
| 2107 | end if |
---|
[190] | 2108 | if (xe .EQ. -1) then |
---|
| 2109 | res@trXMaxF = maxiwsptsBC |
---|
[162] | 2110 | else |
---|
| 2111 | res@trXMaxF = xe |
---|
[190] | 2112 | end if |
---|
[175] | 2113 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2114 | end if |
---|
| 2115 | end if |
---|
| 2116 | if (vNam(varn) .EQ. "wptBC") then |
---|
| 2117 | miniwptBC=min(data(varn,:,:)) |
---|
| 2118 | maxiwptBC=max(data(varn,:,:)) |
---|
| 2119 | if (over .EQ. 1) then |
---|
| 2120 | res@xyDashPattern = 1 |
---|
[175] | 2121 | plot_wptBC = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2122 | else |
---|
| 2123 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2124 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2125 | res@gsnRightString = " " |
---|
[190] | 2126 | if (xs .EQ. -1) then |
---|
| 2127 | res@trXMinF = miniwptBC |
---|
[162] | 2128 | else |
---|
| 2129 | res@trXMinF = xs |
---|
| 2130 | end if |
---|
[190] | 2131 | if (xe .EQ. -1) then |
---|
| 2132 | res@trXMaxF = maxiwptBC |
---|
[162] | 2133 | else |
---|
| 2134 | res@trXMaxF = xe |
---|
| 2135 | end if |
---|
[175] | 2136 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2137 | end if |
---|
| 2138 | end if |
---|
| 2139 | |
---|
| 2140 | if (vNam(varn) .EQ. "wpvptp") then |
---|
| 2141 | miniwpvptp=min(data(varn,:,:)) |
---|
| 2142 | maxiwpvptp=max(data(varn,:,:)) |
---|
| 2143 | if (over .EQ. 1) then |
---|
| 2144 | res@xyDashPattern = 0 |
---|
[175] | 2145 | plot_wpvptp = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2146 | else |
---|
| 2147 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2148 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2149 | res@gsnRightString = " " |
---|
[190] | 2150 | if (xs .EQ. -1) then |
---|
| 2151 | res@trXMinF = miniwpvptp |
---|
[162] | 2152 | else |
---|
| 2153 | res@trXMinF = xs |
---|
| 2154 | end if |
---|
[190] | 2155 | if (xe .EQ. -1) then |
---|
| 2156 | res@trXMaxF = maxiwpvptp |
---|
[162] | 2157 | else |
---|
| 2158 | res@trXMaxF = xe |
---|
[190] | 2159 | end if |
---|
[175] | 2160 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2161 | end if |
---|
| 2162 | end if |
---|
| 2163 | if (vNam(varn) .EQ. "wsvpts") then |
---|
| 2164 | miniwsvpts=min(data(varn,:,:)) |
---|
| 2165 | maxiwsvpts=max(data(varn,:,:)) |
---|
| 2166 | if (over .EQ. 1) then |
---|
| 2167 | res@xyDashPattern = 1 |
---|
[175] | 2168 | plot_wsvpts = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2169 | else |
---|
| 2170 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2171 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2172 | res@gsnRightString = " " |
---|
[190] | 2173 | if (xs .EQ. -1) then |
---|
| 2174 | res@trXMinF = miniwsvpts |
---|
[162] | 2175 | else |
---|
| 2176 | res@trXMinF = xs |
---|
| 2177 | end if |
---|
[190] | 2178 | if (xe .EQ. -1) then |
---|
| 2179 | res@trXMaxF = maxiwsvpts |
---|
[162] | 2180 | else |
---|
| 2181 | res@trXMaxF = xe |
---|
[190] | 2182 | end if |
---|
[175] | 2183 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2184 | end if |
---|
| 2185 | end if |
---|
| 2186 | if (vNam(varn) .EQ. "wvpt") then |
---|
| 2187 | miniwvpt=min(data(varn,:,:)) |
---|
| 2188 | maxiwvpt=max(data(varn,:,:)) |
---|
| 2189 | if (over .EQ. 1) then |
---|
| 2190 | res@xyDashPattern = 2 |
---|
[175] | 2191 | plot_wvpt = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2192 | else |
---|
| 2193 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2194 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2195 | res@gsnRightString = " " |
---|
[190] | 2196 | if (xs .EQ. -1) then |
---|
| 2197 | res@trXMinF = miniwvpt |
---|
[162] | 2198 | else |
---|
| 2199 | res@trXMinF = xs |
---|
| 2200 | end if |
---|
[190] | 2201 | if (xe .EQ. -1) then |
---|
| 2202 | res@trXMaxF = maxiwvpt |
---|
[162] | 2203 | else |
---|
| 2204 | res@trXMaxF = xe |
---|
| 2205 | end if |
---|
[175] | 2206 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2207 | end if |
---|
| 2208 | end if |
---|
| 2209 | |
---|
| 2210 | if (vNam(varn) .EQ. "wpqp") then |
---|
| 2211 | miniwpqp=min(data(varn,:,:)) |
---|
| 2212 | maxiwpqp=max(data(varn,:,:)) |
---|
| 2213 | if (over .EQ. 1) then |
---|
| 2214 | res@xyDashPattern = 0 |
---|
[175] | 2215 | plot_wpqp = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2216 | else |
---|
| 2217 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2218 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2219 | res@gsnRightString = " " |
---|
[190] | 2220 | if (xs .EQ. -1) then |
---|
| 2221 | res@trXMinF = miniwpqp |
---|
[162] | 2222 | else |
---|
| 2223 | res@trXMinF = xs |
---|
| 2224 | end if |
---|
[190] | 2225 | if (xe .EQ. -1) then |
---|
| 2226 | res@trXMaxF = maxiwpqp |
---|
[162] | 2227 | else |
---|
| 2228 | res@trXMaxF = xe |
---|
| 2229 | end if |
---|
[175] | 2230 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2231 | end if |
---|
| 2232 | end if |
---|
| 2233 | if (vNam(varn) .EQ. "wsqs") then |
---|
| 2234 | miniwsqs=min(data(varn,:,:)) |
---|
| 2235 | maxiwsqs=max(data(varn,:,:)) |
---|
| 2236 | if (over .EQ. 1) then |
---|
| 2237 | res@xyDashPattern = 1 |
---|
[175] | 2238 | plot_wsqs = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2239 | else |
---|
| 2240 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2241 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2242 | res@gsnRightString = " " |
---|
[190] | 2243 | if (xs .EQ. -1) then |
---|
| 2244 | res@trXMinF = miniwsqs |
---|
[162] | 2245 | else |
---|
| 2246 | res@trXMinF = xs |
---|
| 2247 | end if |
---|
[190] | 2248 | if (xe .EQ. -1) then |
---|
| 2249 | res@trXMaxF = maxiwsqs |
---|
[162] | 2250 | else |
---|
| 2251 | res@trXMaxF = xe |
---|
| 2252 | end if |
---|
[175] | 2253 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2254 | end if |
---|
| 2255 | end if |
---|
| 2256 | if (vNam(varn) .EQ. "wq") then |
---|
| 2257 | miniwq=min(data(varn,:,:)) |
---|
| 2258 | maxiwq=max(data(varn,:,:)) |
---|
| 2259 | if (over .EQ. 1) then |
---|
| 2260 | res@xyDashPattern = 2 |
---|
[175] | 2261 | plot_wq = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2262 | else |
---|
| 2263 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2264 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2265 | res@gsnRightString = " " |
---|
[190] | 2266 | if (xs .EQ. -1) then |
---|
| 2267 | res@trXMinF = miniwq |
---|
[162] | 2268 | else |
---|
| 2269 | res@trXMinF = xs |
---|
| 2270 | end if |
---|
[190] | 2271 | if (xe .EQ. -1) then |
---|
| 2272 | res@trXMaxF = maxiwq |
---|
[162] | 2273 | else |
---|
| 2274 | res@trXMaxF = xe |
---|
[190] | 2275 | end if |
---|
[175] | 2276 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2277 | end if |
---|
| 2278 | end if |
---|
| 2279 | |
---|
| 2280 | if (vNam(varn) .EQ. "wpqvp") then |
---|
| 2281 | miniwpqvp=min(data(varn,:,:)) |
---|
| 2282 | maxiwpqvp=max(data(varn,:,:)) |
---|
| 2283 | if (over .EQ. 1) then |
---|
| 2284 | res@xyDashPattern = 0 |
---|
[175] | 2285 | plot_wpqvp = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2286 | else |
---|
| 2287 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2288 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2289 | res@gsnRightString = " " |
---|
[190] | 2290 | if (xs .EQ. -1) then |
---|
| 2291 | res@trXMinF = miniwpqvp |
---|
[162] | 2292 | else |
---|
| 2293 | res@trXMinF = xs |
---|
| 2294 | end if |
---|
[190] | 2295 | if (xe .EQ. -1) then |
---|
| 2296 | res@trXMaxF = maxiwpqvp |
---|
[162] | 2297 | else |
---|
| 2298 | res@trXMaxF = xe |
---|
[190] | 2299 | end if |
---|
[175] | 2300 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2301 | end if |
---|
| 2302 | end if |
---|
| 2303 | if (vNam(varn) .EQ. "wsqvs") then |
---|
| 2304 | miniwsqvs=min(data(varn,:,:)) |
---|
| 2305 | maxiwsqvs=max(data(varn,:,:)) |
---|
| 2306 | if (over .EQ. 1) then |
---|
| 2307 | res@xyDashPattern = 1 |
---|
[175] | 2308 | plot_wsqvs = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2309 | else |
---|
| 2310 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2311 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2312 | res@gsnRightString = " " |
---|
[190] | 2313 | if (xs .EQ. -1) then |
---|
| 2314 | res@trXMinF = miniwsqvs |
---|
[162] | 2315 | else |
---|
| 2316 | res@trXMinF = xs |
---|
| 2317 | end if |
---|
[190] | 2318 | if (xe .EQ. -1) then |
---|
| 2319 | res@trXMaxF = maxiwsqvs |
---|
[162] | 2320 | else |
---|
| 2321 | res@trXMaxF = xe |
---|
| 2322 | end if |
---|
[175] | 2323 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2324 | end if |
---|
| 2325 | end if |
---|
| 2326 | if (vNam(varn) .EQ. "wqv") then |
---|
| 2327 | miniwqv=min(data(varn,:,:)) |
---|
| 2328 | maxiwqv=max(data(varn,:,:)) |
---|
| 2329 | if (over .EQ. 1) then |
---|
| 2330 | res@xyDashPattern = 2 |
---|
[175] | 2331 | plot_wqv = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2332 | else |
---|
| 2333 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2334 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2335 | res@gsnRightString = " " |
---|
[190] | 2336 | if (xs .EQ. -1) then |
---|
| 2337 | res@trXMinF = miniwqv |
---|
[162] | 2338 | else |
---|
| 2339 | res@trXMinF = xs |
---|
| 2340 | end if |
---|
[190] | 2341 | if (xe .EQ. -1) then |
---|
| 2342 | res@trXMaxF = maxiwqv |
---|
[162] | 2343 | else |
---|
| 2344 | res@trXMaxF = xe |
---|
| 2345 | end if |
---|
[175] | 2346 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2347 | end if |
---|
| 2348 | end if |
---|
| 2349 | |
---|
| 2350 | if (vNam(varn) .EQ. "wpsp") then |
---|
| 2351 | miniwpsp=min(data(varn,:,:)) |
---|
| 2352 | maxiwpsp=max(data(varn,:,:)) |
---|
| 2353 | if (over .EQ. 1) then |
---|
| 2354 | res@xyDashPattern = 0 |
---|
[175] | 2355 | plot_wpsp = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2356 | else |
---|
| 2357 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2358 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2359 | res@gsnRightString = " " |
---|
[190] | 2360 | if (xs .EQ. -1) then |
---|
| 2361 | res@trXMinF = miniwpsp |
---|
[162] | 2362 | else |
---|
| 2363 | res@trXMinF = xs |
---|
| 2364 | end if |
---|
[190] | 2365 | if (xe .EQ. -1) then |
---|
| 2366 | res@trXMaxF = maxiwpsp |
---|
[162] | 2367 | else |
---|
| 2368 | res@trXMaxF = xe |
---|
| 2369 | end if |
---|
[175] | 2370 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2371 | end if |
---|
| 2372 | end if |
---|
| 2373 | if (vNam(varn) .EQ. "wsss") then |
---|
| 2374 | miniwsss=min(data(varn,:,:)) |
---|
| 2375 | maxiwsss=max(data(varn,:,:)) |
---|
| 2376 | if (over .EQ. 1) then |
---|
| 2377 | res@xyDashPattern = 1 |
---|
[175] | 2378 | plot_wsss = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2379 | else |
---|
| 2380 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2381 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2382 | res@gsnRightString = " " |
---|
[190] | 2383 | if (xs .EQ. -1) then |
---|
| 2384 | res@trXMinF = miniwsss |
---|
[162] | 2385 | else |
---|
| 2386 | res@trXMinF = xs |
---|
| 2387 | end if |
---|
[190] | 2388 | if (xe .EQ. -1) then |
---|
| 2389 | res@trXMaxF = maxiwsss |
---|
[162] | 2390 | else |
---|
| 2391 | res@trXMaxF = xe |
---|
| 2392 | end if |
---|
[175] | 2393 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2394 | end if |
---|
| 2395 | end if |
---|
| 2396 | if (vNam(varn) .EQ. "ws") then |
---|
| 2397 | miniws=min(data(varn,:,:)) |
---|
| 2398 | maxiws=max(data(varn,:,:)) |
---|
| 2399 | if (over .EQ. 1) then |
---|
| 2400 | res@xyDashPattern = 2 |
---|
[175] | 2401 | plot_ws = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2402 | else |
---|
| 2403 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2404 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2405 | res@gsnRightString = " " |
---|
[190] | 2406 | if (xs .EQ. -1) then |
---|
| 2407 | res@trXMinF = miniws |
---|
[162] | 2408 | else |
---|
| 2409 | res@trXMinF = xs |
---|
| 2410 | end if |
---|
[190] | 2411 | if (xe .EQ. -1) then |
---|
| 2412 | res@trXMaxF = maxiws |
---|
[162] | 2413 | else |
---|
| 2414 | res@trXMaxF = xe |
---|
| 2415 | end if |
---|
[175] | 2416 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2417 | end if |
---|
| 2418 | end if |
---|
| 2419 | |
---|
| 2420 | if (vNam(varn) .EQ. "wpsap") then |
---|
| 2421 | miniwpsap=min(data(varn,:,:)) |
---|
| 2422 | maxiwpsap=max(data(varn,:,:)) |
---|
| 2423 | if (over .EQ. 1) then |
---|
| 2424 | res@xyDashPattern = 0 |
---|
[175] | 2425 | plot_wpsap = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2426 | else |
---|
| 2427 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2428 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2429 | res@gsnRightString = " " |
---|
[190] | 2430 | if (xs .EQ. -1) then |
---|
| 2431 | res@trXMinF = miniwpsap |
---|
[162] | 2432 | else |
---|
| 2433 | res@trXMinF = xs |
---|
| 2434 | end if |
---|
[190] | 2435 | if (xe .EQ. -1) then |
---|
| 2436 | res@trXMaxF = maxiwpsap |
---|
[162] | 2437 | else |
---|
| 2438 | res@trXMaxF = xe |
---|
[190] | 2439 | end if |
---|
[175] | 2440 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2441 | end if |
---|
| 2442 | end if |
---|
| 2443 | if (vNam(varn) .EQ. "wssas") then |
---|
| 2444 | miniwssas=min(data(varn,:,:)) |
---|
| 2445 | maxiwssas=max(data(varn,:,:)) |
---|
| 2446 | if (over .EQ. 1) then |
---|
| 2447 | res@xyDashPattern = 1 |
---|
[175] | 2448 | plot_wssas = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2449 | else |
---|
| 2450 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2451 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2452 | res@gsnRightString = " " |
---|
[190] | 2453 | if (xs .EQ. -1) then |
---|
| 2454 | res@trXMinF = miniwssas |
---|
[162] | 2455 | else |
---|
| 2456 | res@trXMinF = xs |
---|
| 2457 | end if |
---|
[190] | 2458 | if (xe .EQ. -1) then |
---|
| 2459 | res@trXMaxF = maxiwssas |
---|
[162] | 2460 | else |
---|
| 2461 | res@trXMaxF = xe |
---|
[190] | 2462 | end if |
---|
[175] | 2463 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2464 | end if |
---|
| 2465 | end if |
---|
| 2466 | if (vNam(varn) .EQ. "wsa") then |
---|
| 2467 | miniwsa=min(data(varn,:,:)) |
---|
| 2468 | maxiwsa=max(data(varn,:,:)) |
---|
| 2469 | if (over .EQ. 1) then |
---|
| 2470 | res@xyDashPattern = 2 |
---|
[175] | 2471 | plot_wsa = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2472 | else |
---|
| 2473 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2474 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2475 | res@gsnRightString = " " |
---|
[190] | 2476 | if (xs .EQ. -1) then |
---|
| 2477 | res@trXMinF = miniwsa |
---|
[162] | 2478 | else |
---|
| 2479 | res@trXMinF = xs |
---|
| 2480 | end if |
---|
[190] | 2481 | if (xe .EQ. -1) then |
---|
| 2482 | res@trXMaxF = maxiwsa |
---|
[162] | 2483 | else |
---|
| 2484 | res@trXMaxF = xe |
---|
[190] | 2485 | end if |
---|
[175] | 2486 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2487 | end if |
---|
| 2488 | end if |
---|
| 2489 | |
---|
| 2490 | if (vNam(varn) .EQ. "us2") then |
---|
| 2491 | minius2=min(data(varn,:,:)) |
---|
| 2492 | maxius2=max(data(varn,:,:)) |
---|
| 2493 | if (over .EQ. 1) then |
---|
| 2494 | res@xyDashPattern = 0 |
---|
[175] | 2495 | plot_us2 = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2496 | else |
---|
| 2497 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2498 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2499 | res@gsnRightString = " " |
---|
[190] | 2500 | if (xs .EQ. -1) then |
---|
| 2501 | res@trXMinF = minius2 |
---|
[162] | 2502 | else |
---|
| 2503 | res@trXMinF = xs |
---|
| 2504 | end if |
---|
[190] | 2505 | if (xe .EQ. -1) then |
---|
| 2506 | res@trXMaxF = maxius2 |
---|
[162] | 2507 | else |
---|
| 2508 | res@trXMaxF = xe |
---|
[190] | 2509 | end if |
---|
[175] | 2510 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2511 | end if |
---|
| 2512 | end if |
---|
| 2513 | if (vNam(varn) .EQ. "vs2") then |
---|
| 2514 | minivs2=min(data(varn,:,:)) |
---|
| 2515 | maxivs2=max(data(varn,:,:)) |
---|
| 2516 | if (over .EQ. 1) then |
---|
| 2517 | res@xyDashPattern = 1 |
---|
[175] | 2518 | plot_vs2 = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2519 | else |
---|
| 2520 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2521 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2522 | res@gsnRightString = " " |
---|
[190] | 2523 | if (xs .EQ. -1) then |
---|
| 2524 | res@trXMinF = minivs2 |
---|
[162] | 2525 | else |
---|
| 2526 | res@trXMinF = xs |
---|
| 2527 | end if |
---|
[190] | 2528 | if (xe .EQ. -1) then |
---|
| 2529 | res@trXMaxF = maxivs2 |
---|
[162] | 2530 | else |
---|
| 2531 | res@trXMaxF = xe |
---|
[190] | 2532 | end if |
---|
[175] | 2533 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2534 | end if |
---|
| 2535 | end if |
---|
| 2536 | if (vNam(varn) .EQ. "ws2") then |
---|
| 2537 | miniws2=min(data(varn,:,:)) |
---|
| 2538 | maxiws2=max(data(varn,:,:)) |
---|
| 2539 | if (over .EQ. 1) then |
---|
| 2540 | res@xyDashPattern = 2 |
---|
[175] | 2541 | plot_ws2 = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2542 | else |
---|
| 2543 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2544 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2545 | res@gsnRightString = " " |
---|
[190] | 2546 | if (xs .EQ. -1) then |
---|
| 2547 | res@trXMinF = miniws2 |
---|
[162] | 2548 | else |
---|
| 2549 | res@trXMinF = xs |
---|
| 2550 | end if |
---|
[190] | 2551 | if (xe .EQ. -1) then |
---|
| 2552 | res@trXMaxF = maxiws2 |
---|
[162] | 2553 | else |
---|
| 2554 | res@trXMaxF = xe |
---|
[190] | 2555 | end if |
---|
[175] | 2556 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2557 | end if |
---|
| 2558 | end if |
---|
| 2559 | |
---|
| 2560 | if (vNam(varn) .EQ. "wsususodz") then |
---|
| 2561 | miniwsususodz=min(data(varn,:,:)) |
---|
| 2562 | maxiwsususodz=max(data(varn,:,:)) |
---|
| 2563 | if (over .EQ. 1) then |
---|
| 2564 | res@xyDashPattern = 0 |
---|
[175] | 2565 | plot_wsususodz = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2566 | else |
---|
| 2567 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2568 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2569 | res@gsnRightString = " " |
---|
[190] | 2570 | if (xs .EQ. -1) then |
---|
| 2571 | res@trXMinF = miniwsususodz |
---|
[162] | 2572 | else |
---|
| 2573 | res@trXMinF = xs |
---|
| 2574 | end if |
---|
[190] | 2575 | if (xe .EQ. -1) then |
---|
| 2576 | res@trXMaxF = maxiwsususodz |
---|
[162] | 2577 | else |
---|
| 2578 | res@trXMaxF = xe |
---|
[190] | 2579 | end if |
---|
[175] | 2580 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2581 | end if |
---|
| 2582 | end if |
---|
| 2583 | if (vNam(varn) .EQ. "wspsodz") then |
---|
| 2584 | miniwspsodz=min(data(varn,:,:)) |
---|
| 2585 | maxiwspsodz=max(data(varn,:,:)) |
---|
| 2586 | if (over .EQ. 1) then |
---|
| 2587 | res@xyDashPattern = 1 |
---|
[175] | 2588 | plot_wspsodz = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2589 | else |
---|
| 2590 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2591 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2592 | res@gsnRightString = " " |
---|
[190] | 2593 | if (xs .EQ. -1) then |
---|
| 2594 | res@trXMinF = miniwspsodz |
---|
[162] | 2595 | else |
---|
| 2596 | res@trXMinF = xs |
---|
| 2597 | end if |
---|
[190] | 2598 | if (xe .EQ. -1) then |
---|
| 2599 | res@trXMaxF = maxiwspsodz |
---|
[162] | 2600 | else |
---|
| 2601 | res@trXMaxF = xe |
---|
[190] | 2602 | end if |
---|
[175] | 2603 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2604 | end if |
---|
| 2605 | end if |
---|
| 2606 | if (vNam(varn) .EQ. "wpeodz") then |
---|
| 2607 | miniwpeodz=min(data(varn,:,:)) |
---|
| 2608 | maxiwpeodz=max(data(varn,:,:)) |
---|
| 2609 | if (over .EQ. 1) then |
---|
| 2610 | res@xyDashPattern = 2 |
---|
[175] | 2611 | plot_wpeodz = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2612 | else |
---|
| 2613 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2614 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2615 | res@gsnRightString = " " |
---|
[190] | 2616 | if (xs .EQ. -1) then |
---|
| 2617 | res@trXMinF = miniwpeodz |
---|
[162] | 2618 | else |
---|
| 2619 | res@trXMinF = xs |
---|
| 2620 | end if |
---|
[190] | 2621 | if (xe .EQ. -1) then |
---|
| 2622 | res@trXMaxF = maxiwpeodz |
---|
[162] | 2623 | else |
---|
| 2624 | res@trXMaxF = xe |
---|
[190] | 2625 | end if |
---|
[175] | 2626 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2627 | end if |
---|
| 2628 | end if |
---|
[175] | 2629 | if (no_files .GT. 1) then |
---|
| 2630 | multi_plot(nof,n)=plot(n) |
---|
| 2631 | max_nof(nof,n)=max(data(varn,:,:)) |
---|
| 2632 | min_nof(nof,n)=min(data(varn,:,:)) |
---|
| 2633 | name(nof,n) =vNam(varn) |
---|
| 2634 | unit_(nof,n) =unit(varn) |
---|
| 2635 | end if |
---|
[161] | 2636 | if (over .EQ. 0) then |
---|
| 2637 | n=n+1 |
---|
[174] | 2638 | end if |
---|
| 2639 | if (prof3d .EQ. 0)then |
---|
| 2640 | varn=varn+1 |
---|
| 2641 | end if |
---|
| 2642 | delete(temp) |
---|
| 2643 | end if |
---|
[154] | 2644 | end do |
---|
[175] | 2645 | if (no_files .GT. 1) then |
---|
| 2646 | delete(vNam) |
---|
[218] | 2647 | delete(files) |
---|
[175] | 2648 | end if |
---|
[218] | 2649 | |
---|
[175] | 2650 | end do |
---|
[218] | 2651 | ;#########ENDE DO LOOP FOR no_files GT 1############# |
---|
| 2652 | |
---|
[162] | 2653 | if (count_var .EQ. 0) then |
---|
| 2654 | print(" ") |
---|
[190] | 2655 | print("The variables 'var="+var+"' do not exist on your input file;") |
---|
| 2656 | print("be sure to have one comma berfore and after each variable") |
---|
[175] | 2657 | print(" ") |
---|
| 2658 | exit |
---|
| 2659 | end if |
---|
| 2660 | |
---|
| 2661 | if (no_files .GT. 1) then |
---|
[218] | 2662 | multi_legend=new(6,string) |
---|
| 2663 | string_len=new(6,integer) |
---|
[175] | 2664 | multi_dash=new(no_files,string) |
---|
[190] | 2665 | multi_legend(0)=" "+name_legend_1 |
---|
[175] | 2666 | string_len(0)=strlen(multi_legend(0)) |
---|
[190] | 2667 | multi_legend(1)=" "+name_legend_2 |
---|
[175] | 2668 | string_len(1)=strlen(multi_legend(1)) |
---|
[190] | 2669 | multi_legend(2)=" "+name_legend_3 |
---|
[175] | 2670 | string_len(2)=strlen(multi_legend(2)) |
---|
[190] | 2671 | multi_legend(3)=" "+name_legend_4 |
---|
[175] | 2672 | string_len(3)=strlen(multi_legend(3)) |
---|
[190] | 2673 | multi_legend(4)=" "+name_legend_5 |
---|
[175] | 2674 | string_len(4)=strlen(multi_legend(4)) |
---|
[190] | 2675 | multi_legend(5)=" "+name_legend_6 |
---|
[175] | 2676 | string_len(5)=strlen(multi_legend(5)) |
---|
| 2677 | do ml=1,no_files |
---|
| 2678 | multi_dash(ml-1)=ml-1 |
---|
| 2679 | end do |
---|
| 2680 | delete(plot) |
---|
| 2681 | plot = new(dim,graphic) |
---|
| 2682 | do pl=0,n-1 |
---|
| 2683 | plot0 = new(1,graphic) |
---|
| 2684 | res@trXMinF = min(min_nof(:,pl)) |
---|
| 2685 | res@trXMaxF = max(max_nof(:,pl)) |
---|
| 2686 | res@gsnLeftString = name(0,pl) |
---|
| 2687 | res@gsnRightString = unit_(0,pl) |
---|
| 2688 | |
---|
| 2689 | plot0 = gsn_csm_xy(wks,data_0(:,:),z_(pl,:),res) |
---|
| 2690 | |
---|
| 2691 | ; *************************************************** |
---|
| 2692 | ; legend for combined plot |
---|
| 2693 | ; *************************************************** |
---|
| 2694 | |
---|
| 2695 | lgres = True |
---|
| 2696 | lgMonoDashIndex = False |
---|
| 2697 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 2698 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[175] | 2699 | lgres@vpWidthF = max(string_len)*0.012 |
---|
| 2700 | lgres@vpHeightF = 0.04*no_files |
---|
| 2701 | lgres@lgDashIndexes = multi_dash(no_files-1:0) |
---|
| 2702 | lbid = gsn_create_legend(wks,no_files,multi_legend(no_files-1:0),lgres) |
---|
| 2703 | |
---|
| 2704 | amres = True |
---|
| 2705 | amres@amParallelPosF = max(string_len)*0.01+0.78 |
---|
| 2706 | amres@amOrthogonalPosF = -0.0315*no_files+0.431 |
---|
| 2707 | annoid1 = gsn_add_annotation(plot0,lbid,amres) |
---|
| 2708 | |
---|
| 2709 | do plo=0,no_files-1 |
---|
| 2710 | overlay(plot0,multi_plot(plo,pl)) |
---|
| 2711 | plot(pl)=plot0 |
---|
| 2712 | end do |
---|
| 2713 | delete(plot0) |
---|
| 2714 | end do |
---|
| 2715 | end if |
---|
| 2716 | |
---|
| 2717 | if (count_var .EQ. 0) then |
---|
| 2718 | print(" ") |
---|
[218] | 2719 | print("Select a variable 'var=' or use the default value") |
---|
[162] | 2720 | print(" ") |
---|
| 2721 | print("Your selection '"+var+"' does not exist on the input file") |
---|
| 2722 | print(" ") |
---|
| 2723 | exit |
---|
| 2724 | end if |
---|
| 2725 | |
---|
[161] | 2726 | if (over .EQ. 1 ) then |
---|
[154] | 2727 | |
---|
[161] | 2728 | overlay(plot_u,plot_v) |
---|
| 2729 | overlay(plot_u,plot_w) |
---|
| 2730 | u=0 |
---|
| 2731 | overlay(plot_pt,plot_vpt) |
---|
| 2732 | overlay(plot_pt,plot_lpt) |
---|
| 2733 | pt=0 |
---|
| 2734 | overlay(plot_q,plot_qv) |
---|
| 2735 | overlay(plot_q,plot_ql) |
---|
| 2736 | q=0 |
---|
| 2737 | overlay(plot_e,plot_es) |
---|
| 2738 | e=0 |
---|
| 2739 | overlay(plot_km,plot_kh) |
---|
| 2740 | km=0 |
---|
| 2741 | overlay(plot_wpup,plot_wsus) |
---|
| 2742 | overlay(plot_wpup,plot_wu) |
---|
| 2743 | wpup=0 |
---|
| 2744 | overlay(plot_wpvp,plot_wsvs) |
---|
| 2745 | overlay(plot_wpvp,plot_wv) |
---|
| 2746 | wpvp=0 |
---|
| 2747 | overlay(plot_wpptp,plot_wspts) |
---|
| 2748 | overlay(plot_wpptp,plot_wpt) |
---|
| 2749 | wpptp=0 |
---|
| 2750 | overlay(plot_wsptsBC,plot_wptBC) |
---|
| 2751 | wsptsBC=0 |
---|
| 2752 | overlay(plot_wpvptp,plot_wsvpts) |
---|
| 2753 | overlay(plot_wpvptp,plot_wvpt) |
---|
| 2754 | wpvptp=0 |
---|
| 2755 | overlay(plot_wpqp,plot_wsqs) |
---|
| 2756 | overlay(plot_wpqp,plot_wq) |
---|
| 2757 | wpqp=0 |
---|
| 2758 | overlay(plot_wpqvp,plot_wsqvs) |
---|
| 2759 | overlay(plot_wpqvp,plot_wqv) |
---|
| 2760 | wpqvp=0 |
---|
| 2761 | overlay(plot_wpsp,plot_wsss) |
---|
| 2762 | overlay(plot_wpsp,plot_ws) |
---|
| 2763 | wpsp=0 |
---|
| 2764 | overlay(plot_wpsap,plot_wssas) |
---|
| 2765 | overlay(plot_wpsap,plot_wsa) |
---|
| 2766 | wpsap=0 |
---|
| 2767 | overlay(plot_us2,plot_vs2) |
---|
| 2768 | overlay(plot_us2,plot_ws2) |
---|
| 2769 | us2=0 |
---|
| 2770 | overlay(plot_wsususodz,plot_wspsodz) |
---|
| 2771 | overlay(plot_wsususodz,plot_wpeodz) |
---|
| 2772 | wsususodz=0 |
---|
| 2773 | |
---|
| 2774 | end if |
---|
| 2775 | |
---|
| 2776 | if (over .EQ. 1) then |
---|
| 2777 | |
---|
| 2778 | do varn = 0,dim-1 |
---|
[174] | 2779 | |
---|
| 2780 | check = True |
---|
[161] | 2781 | |
---|
[174] | 2782 | if (prof3d .EQ. 0) then |
---|
| 2783 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then |
---|
| 2784 | check = False |
---|
| 2785 | end if |
---|
[161] | 2786 | else |
---|
[174] | 2787 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "zusi") .OR. isStrSubset( vNam(varn), "zwwi") .OR. isStrSubset( vNam(varn), "x") .OR. isStrSubset( vNam(varn), "xu") .OR. isStrSubset( vNam(varn), "y") .OR. isStrSubset( vNam(varn), "yv") .OR. isStrSubset( vNam(varn), "zu_3d") .OR. isStrSubset( vNam(varn), "zw_3d")) then |
---|
| 2788 | check = False |
---|
| 2789 | end if |
---|
| 2790 | end if |
---|
| 2791 | |
---|
[190] | 2792 | if (var .NE. "all") then |
---|
[174] | 2793 | check = isStrSubset( var,","+vNam(varn)+"," ) |
---|
| 2794 | end if |
---|
[161] | 2795 | |
---|
[175] | 2796 | if (check)then |
---|
[174] | 2797 | |
---|
| 2798 | if (prof3d .EQ. 0) then |
---|
[218] | 2799 | if (log_z .EQ. 1) then |
---|
[250] | 2800 | z = f_att->$vNam(varn+1)$(1:dimz-1) |
---|
[175] | 2801 | else |
---|
[250] | 2802 | z = f_att->$vNam(varn+1)$ |
---|
[175] | 2803 | end if |
---|
| 2804 | else |
---|
| 2805 | do i=0,b-1 |
---|
| 2806 | if (isStrSubset( a(i),"zu_3d" ))then |
---|
| 2807 | z_v(varn,:) = z_u |
---|
[218] | 2808 | if (log_z .EQ. 1) then |
---|
[175] | 2809 | z = z_v(varn,1:dimz-1) |
---|
| 2810 | else |
---|
| 2811 | z = z_v(varn,:) |
---|
| 2812 | end if |
---|
| 2813 | else |
---|
| 2814 | if (isStrSubset( a(i),"zw_3d" ))then |
---|
| 2815 | z_v(varn,:) = z_w |
---|
[218] | 2816 | if (log_z .EQ. 1) then |
---|
[175] | 2817 | z = z_v(varn,1:dimz-1) |
---|
| 2818 | else |
---|
| 2819 | z = z_v(varn,:) |
---|
| 2820 | end if |
---|
| 2821 | end if |
---|
| 2822 | end if |
---|
| 2823 | end do |
---|
[174] | 2824 | end if |
---|
| 2825 | |
---|
[218] | 2826 | z=z/norm_z |
---|
[175] | 2827 | |
---|
[162] | 2828 | res@gsnLeftString = vNam(varn) |
---|
[218] | 2829 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2830 | res@gsnRightString = " " |
---|
[161] | 2831 | res@trYMinF = min_z |
---|
| 2832 | res@trYMaxF = max_z |
---|
[250] | 2833 | res@xyDashPattern = 0 |
---|
| 2834 | |
---|
[190] | 2835 | if (xs .EQ. -1) then |
---|
| 2836 | res@trXMinF = min(data(varn,:,:)) |
---|
[162] | 2837 | else |
---|
| 2838 | res@trXMinF = xs |
---|
| 2839 | end if |
---|
[190] | 2840 | if (xe .EQ. -1) then |
---|
| 2841 | res@trXMaxF = max(data(varn,:,:)) |
---|
[162] | 2842 | else |
---|
| 2843 | res@trXMaxF = xe |
---|
| 2844 | end if |
---|
[161] | 2845 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
| 2846 | |
---|
| 2847 | if (vNam(varn) .EQ. "u" .OR. vNam(varn) .EQ. "v" .OR. vNam(varn) .EQ. "w") then |
---|
| 2848 | if (u .EQ. 0) then |
---|
| 2849 | res@gsnLeftString = "u, v and w" |
---|
[218] | 2850 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2851 | res@gsnRightString = " " |
---|
[190] | 2852 | if (xs .EQ. -1) then |
---|
| 2853 | res@trXMinF = min((/miniu,miniv,miniw/)) |
---|
[162] | 2854 | else |
---|
| 2855 | res@trXMinF = xs |
---|
| 2856 | end if |
---|
[190] | 2857 | if (xe .EQ. -1) then |
---|
| 2858 | res@trXMaxF = max((/maxiu,maxiv,maxiw/)) |
---|
[162] | 2859 | else |
---|
| 2860 | res@trXMaxF = xe |
---|
[175] | 2861 | end if |
---|
[250] | 2862 | if (vNam(varn) .EQ. "v")then |
---|
| 2863 | res@xyDashPattern = 1 |
---|
| 2864 | end if |
---|
| 2865 | if (vNam(varn) .EQ. "w")then |
---|
| 2866 | res@xyDashPattern = 2 |
---|
| 2867 | end if |
---|
[175] | 2868 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2869 | |
---|
| 2870 | ; *************************************************** |
---|
| 2871 | ; legend for combined plot |
---|
| 2872 | ; *************************************************** |
---|
| 2873 | |
---|
| 2874 | lgres = True |
---|
| 2875 | lgMonoDashIndex = False |
---|
| 2876 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 2877 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 2878 | lgres@vpWidthF = 0.06 |
---|
| 2879 | lgres@vpHeightF = 0.12 |
---|
[161] | 2880 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 2881 | lbid = gsn_create_legend(wks,3,(/"u","v","w"/),lgres) |
---|
| 2882 | |
---|
| 2883 | amres = True |
---|
| 2884 | amres@amParallelPosF = 0.65 |
---|
| 2885 | amres@amOrthogonalPosF = -0.2 |
---|
| 2886 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 2887 | overlay(plot(n),plot_u) |
---|
| 2888 | u=1 |
---|
| 2889 | else |
---|
[174] | 2890 | if (prof3d .EQ. 0)then |
---|
| 2891 | varn=varn+1 |
---|
| 2892 | end if |
---|
[161] | 2893 | continue |
---|
| 2894 | end if |
---|
| 2895 | end if |
---|
| 2896 | |
---|
| 2897 | if (vNam(varn) .EQ. "pt" .OR. vNam(varn) .EQ. "vpt" .OR. vNam(varn) .EQ. "lpt") then |
---|
| 2898 | if (pt .EQ. 0) then |
---|
| 2899 | res@gsnLeftString = "pt, vpt and lpt" |
---|
[218] | 2900 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2901 | res@gsnRightString = " " |
---|
[190] | 2902 | if (xs .EQ. -1) then |
---|
| 2903 | res@trXMinF = min((/minipt,minivpt,minilpt/)) |
---|
[162] | 2904 | else |
---|
| 2905 | res@trXMinF = xs |
---|
| 2906 | end if |
---|
[190] | 2907 | if (xe .EQ. -1) then |
---|
| 2908 | res@trXMaxF = max((/maxipt,maxivpt,maxilpt/)) |
---|
[162] | 2909 | else |
---|
| 2910 | res@trXMaxF = xe |
---|
| 2911 | end if |
---|
[250] | 2912 | if (vNam(varn) .EQ. "vpt")then |
---|
| 2913 | res@xyDashPattern = 1 |
---|
| 2914 | end if |
---|
| 2915 | if (vNam(varn) .EQ. "lpt")then |
---|
| 2916 | res@xyDashPattern = 2 |
---|
| 2917 | end if |
---|
[175] | 2918 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2919 | |
---|
| 2920 | ; *************************************************** |
---|
| 2921 | ; legend for combined plot |
---|
| 2922 | ; *************************************************** |
---|
| 2923 | |
---|
| 2924 | lgres = True |
---|
| 2925 | lgMonoDashIndex = False |
---|
| 2926 | lgres@lgLabelFont = "helvetica" |
---|
[250] | 2927 | lgres@lgLabelFontHeightF = font_size_legend |
---|
| 2928 | lgres@vpWidthF = 0.07 |
---|
| 2929 | lgres@vpHeightF = 0.12 |
---|
[161] | 2930 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 2931 | lbid = gsn_create_legend(wks,3,(/"pt","vpt","lpt"/),lgres) |
---|
| 2932 | |
---|
| 2933 | amres = True |
---|
| 2934 | amres@amParallelPosF = 0.65 |
---|
| 2935 | amres@amOrthogonalPosF = -0.2 |
---|
| 2936 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 2937 | overlay(plot(n),plot_pt) |
---|
| 2938 | pt=1 |
---|
| 2939 | else |
---|
[174] | 2940 | if (prof3d .EQ. 0)then |
---|
| 2941 | varn=varn+1 |
---|
| 2942 | end if |
---|
[161] | 2943 | continue |
---|
| 2944 | end if |
---|
| 2945 | end if |
---|
| 2946 | if (vNam(varn) .EQ. "q" .OR. vNam(varn) .EQ. "qv" .OR. vNam(varn) .EQ. "ql") then |
---|
| 2947 | if (q .EQ. 0) then |
---|
| 2948 | res@gsnLeftString = "q, qv and ql" |
---|
[218] | 2949 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 2950 | res@gsnRightString = " " |
---|
[190] | 2951 | if (xs .EQ. -1) then |
---|
| 2952 | res@trXMinF = min((/miniq,miniqv,miniql/)) |
---|
[162] | 2953 | else |
---|
| 2954 | res@trXMinF = xs |
---|
| 2955 | end if |
---|
[190] | 2956 | if (xe .EQ. -1) then |
---|
| 2957 | res@trXMaxF = max((/maxiq,maxiqv,maxiql/)) |
---|
[162] | 2958 | else |
---|
| 2959 | res@trXMaxF = xe |
---|
[190] | 2960 | end if |
---|
[250] | 2961 | if (vNam(varn) .EQ. "qv")then |
---|
| 2962 | res@xyDashPattern = 1 |
---|
| 2963 | end if |
---|
| 2964 | if (vNam(varn) .EQ. "ql")then |
---|
| 2965 | res@xyDashPattern = 2 |
---|
| 2966 | end if |
---|
[175] | 2967 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 2968 | |
---|
| 2969 | ; *************************************************** |
---|
| 2970 | ; legend for combined plot |
---|
| 2971 | ; *************************************************** |
---|
| 2972 | |
---|
| 2973 | lgres = True |
---|
| 2974 | lgMonoDashIndex = False |
---|
| 2975 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 2976 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 2977 | lgres@vpWidthF = 0.06 |
---|
| 2978 | lgres@vpHeightF = 0.12 |
---|
[161] | 2979 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 2980 | lbid = gsn_create_legend(wks,3,(/"q","qv","ql"/),lgres) |
---|
| 2981 | |
---|
| 2982 | amres = True |
---|
| 2983 | amres@amParallelPosF = 0.65 |
---|
| 2984 | amres@amOrthogonalPosF = -0.2 |
---|
| 2985 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 2986 | overlay(plot(n),plot_q) |
---|
| 2987 | q=1 |
---|
| 2988 | else |
---|
[174] | 2989 | if (prof3d .EQ. 0)then |
---|
| 2990 | varn=varn+1 |
---|
| 2991 | end if |
---|
[161] | 2992 | continue |
---|
| 2993 | end if |
---|
[162] | 2994 | end if |
---|
| 2995 | |
---|
[161] | 2996 | if (vNam(varn) .EQ. "e" .OR. vNam(varn) .EQ. "es") then |
---|
| 2997 | if (e .EQ. 0) then |
---|
| 2998 | res@gsnLeftString = "e and es" |
---|
[218] | 2999 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3000 | res@gsnRightString = " " |
---|
[190] | 3001 | if (xs .EQ. -1) then |
---|
| 3002 | res@trXMinF = min((/minie,minies/)) |
---|
[162] | 3003 | else |
---|
| 3004 | res@trXMinF = xs |
---|
| 3005 | end if |
---|
[190] | 3006 | if (xe .EQ. -1) then |
---|
| 3007 | res@trXMaxF = max((/maxie,maxies/)) |
---|
[162] | 3008 | else |
---|
| 3009 | res@trXMaxF = xe |
---|
[190] | 3010 | end if |
---|
[250] | 3011 | if (vNam(varn) .EQ. "es")then |
---|
| 3012 | res@xyDashPattern = 1 |
---|
| 3013 | end if |
---|
[175] | 3014 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3015 | |
---|
| 3016 | ; *************************************************** |
---|
| 3017 | ; legend for combined plot |
---|
| 3018 | ; *************************************************** |
---|
| 3019 | |
---|
| 3020 | lgres = True |
---|
| 3021 | lgMonoDashIndex = False |
---|
| 3022 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3023 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3024 | lgres@vpWidthF = 0.06 |
---|
| 3025 | lgres@vpHeightF = 0.08 |
---|
[161] | 3026 | lgres@lgDashIndexes = (/0,1,2/) |
---|
[250] | 3027 | lbid = gsn_create_legend(wks,2,(/"e","es"/),lgres) |
---|
[161] | 3028 | |
---|
| 3029 | amres = True |
---|
| 3030 | amres@amParallelPosF = 0.65 |
---|
| 3031 | amres@amOrthogonalPosF = -0.2 |
---|
| 3032 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3033 | overlay(plot(n),plot_e) |
---|
| 3034 | e=1 |
---|
| 3035 | else |
---|
[174] | 3036 | if (prof3d .EQ. 0)then |
---|
| 3037 | varn=varn+1 |
---|
| 3038 | end if |
---|
[161] | 3039 | continue |
---|
| 3040 | end if |
---|
| 3041 | end if |
---|
| 3042 | if (vNam(varn) .EQ. "km" .OR. vNam(varn) .EQ. "kh") then |
---|
| 3043 | if (km .EQ. 0) then |
---|
| 3044 | res@gsnLeftString = "km and kh" |
---|
[218] | 3045 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3046 | res@gsnRightString = " " |
---|
[190] | 3047 | if (xs .EQ. -1) then |
---|
| 3048 | res@trXMinF = min((/minikm,minikh/)) |
---|
[162] | 3049 | else |
---|
| 3050 | res@trXMinF = xs |
---|
| 3051 | end if |
---|
[190] | 3052 | if (xe .EQ. -1) then |
---|
| 3053 | res@trXMaxF = max((/maxikm,maxikh/)) |
---|
[162] | 3054 | else |
---|
| 3055 | res@trXMaxF = xe |
---|
[190] | 3056 | end if |
---|
[250] | 3057 | if (vNam(varn) .EQ. "kh")then |
---|
| 3058 | res@xyDashPattern = 1 |
---|
| 3059 | end if |
---|
[175] | 3060 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3061 | |
---|
| 3062 | ; *************************************************** |
---|
| 3063 | ; legend for combined plot |
---|
| 3064 | ; *************************************************** |
---|
| 3065 | |
---|
| 3066 | lgres = True |
---|
| 3067 | lgMonoDashIndex = False |
---|
| 3068 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3069 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3070 | lgres@vpWidthF = 0.06 |
---|
| 3071 | lgres@vpHeightF = 0.08 |
---|
[161] | 3072 | lgres@lgDashIndexes = (/0,1,2/) |
---|
[250] | 3073 | lbid = gsn_create_legend(wks,2,(/"km","kh"/),lgres) |
---|
[161] | 3074 | |
---|
| 3075 | amres = True |
---|
| 3076 | amres@amParallelPosF = 0.65 |
---|
| 3077 | amres@amOrthogonalPosF = -0.2 |
---|
| 3078 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3079 | overlay(plot(n),plot_km) |
---|
| 3080 | km=1 |
---|
| 3081 | else |
---|
[174] | 3082 | if (prof3d .EQ. 0)then |
---|
| 3083 | varn=varn+1 |
---|
| 3084 | end if |
---|
[161] | 3085 | continue |
---|
| 3086 | end if |
---|
| 3087 | end if |
---|
[162] | 3088 | |
---|
[161] | 3089 | if (vNam(varn) .EQ. "wpup" .OR. vNam(varn) .EQ. "wsus" .OR. vNam(varn) .EQ. "wu") then |
---|
| 3090 | if (wpup .EQ. 0) then |
---|
| 3091 | res@gsnLeftString = "wpup, wsus and wu" |
---|
[218] | 3092 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3093 | res@gsnRightString = " " |
---|
[190] | 3094 | if (xs .EQ. -1) then |
---|
| 3095 | res@trXMinF = min((/miniwpup,miniwsus,miniwu/)) |
---|
[162] | 3096 | else |
---|
| 3097 | res@trXMinF = xs |
---|
| 3098 | end if |
---|
[190] | 3099 | if (xe .EQ. -1) then |
---|
| 3100 | res@trXMaxF = max((/maxiwpup,maxiwsus,maxiwu/)) |
---|
[162] | 3101 | else |
---|
| 3102 | res@trXMaxF = xe |
---|
[190] | 3103 | end if |
---|
[250] | 3104 | if (vNam(varn) .EQ. "wsus")then |
---|
| 3105 | res@xyDashPattern = 1 |
---|
| 3106 | end if |
---|
| 3107 | if (vNam(varn) .EQ. "wu")then |
---|
| 3108 | res@xyDashPattern = 2 |
---|
| 3109 | end if |
---|
[175] | 3110 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3111 | |
---|
| 3112 | ; *************************************************** |
---|
| 3113 | ; legend for combined plot |
---|
| 3114 | ; *************************************************** |
---|
| 3115 | |
---|
| 3116 | lgres = True |
---|
| 3117 | lgMonoDashIndex = False |
---|
| 3118 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3119 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3120 | lgres@vpWidthF = 0.08 |
---|
| 3121 | lgres@vpHeightF = 0.12 |
---|
[161] | 3122 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3123 | lbid = gsn_create_legend(wks,3,(/"wpup","wsus","wu"/),lgres) |
---|
| 3124 | |
---|
| 3125 | amres = True |
---|
| 3126 | amres@amParallelPosF = 0.65 |
---|
| 3127 | amres@amOrthogonalPosF = -0.2 |
---|
| 3128 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3129 | overlay(plot(n),plot_wpup) |
---|
| 3130 | wpup=1 |
---|
| 3131 | else |
---|
[174] | 3132 | if (prof3d .EQ. 0)then |
---|
| 3133 | varn=varn+1 |
---|
| 3134 | end if |
---|
[161] | 3135 | continue |
---|
| 3136 | end if |
---|
| 3137 | end if |
---|
| 3138 | if (vNam(varn) .EQ. "wpvp" .OR. vNam(varn) .EQ. "wsvs" .OR.vNam(varn) .EQ. "wv") then |
---|
| 3139 | if (wpvp .EQ. 0) then |
---|
[250] | 3140 | res@gsnLeftString = "wpvp, wsvs and wv" |
---|
[218] | 3141 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3142 | res@gsnRightString = " " |
---|
[190] | 3143 | if (xs .EQ. -1) then |
---|
| 3144 | res@trXMinF = min((/miniwpvp,miniwsvs,miniwv/)) |
---|
[162] | 3145 | else |
---|
| 3146 | res@trXMinF = xs |
---|
| 3147 | end if |
---|
[190] | 3148 | if (xe .EQ. -1) then |
---|
| 3149 | res@trXMaxF = max((/maxiwpvp,maxiwsvs,maxiwv/)) |
---|
[162] | 3150 | else |
---|
| 3151 | res@trXMaxF = xe |
---|
| 3152 | end if |
---|
[250] | 3153 | if (vNam(varn) .EQ. "wsvs")then |
---|
| 3154 | res@xyDashPattern = 1 |
---|
| 3155 | end if |
---|
| 3156 | if (vNam(varn) .EQ. "wv")then |
---|
| 3157 | res@xyDashPattern = 2 |
---|
| 3158 | end if |
---|
[175] | 3159 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3160 | |
---|
| 3161 | ; *************************************************** |
---|
| 3162 | ; legend for combined plot |
---|
| 3163 | ; *************************************************** |
---|
| 3164 | |
---|
| 3165 | lgres = True |
---|
| 3166 | lgMonoDashIndex = False |
---|
| 3167 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3168 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3169 | lgres@vpWidthF = 0.08 |
---|
| 3170 | lgres@vpHeightF = 0.12 |
---|
[161] | 3171 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3172 | lbid = gsn_create_legend(wks,3,(/"wpvp","wsvs","wv"/),lgres) |
---|
| 3173 | |
---|
| 3174 | amres = True |
---|
| 3175 | amres@amParallelPosF = 0.65 |
---|
| 3176 | amres@amOrthogonalPosF = -0.2 |
---|
| 3177 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3178 | overlay(plot(n),plot_wpvp) |
---|
[250] | 3179 | wpvp=1 |
---|
[161] | 3180 | else |
---|
[174] | 3181 | if (prof3d .EQ. 0)then |
---|
| 3182 | varn=varn+1 |
---|
| 3183 | end if |
---|
[161] | 3184 | continue |
---|
| 3185 | end if |
---|
| 3186 | end if |
---|
| 3187 | if (vNam(varn) .EQ. "wpptp" .OR. vNam(varn) .EQ. "wspts" .OR. vNam(varn) .EQ. "wpt") then |
---|
| 3188 | if (wpptp .EQ. 0) then |
---|
[250] | 3189 | res@gsnLeftString = "wpptp, wspts and wpt" |
---|
[218] | 3190 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3191 | res@gsnRightString = " " |
---|
[190] | 3192 | if (xs .EQ. -1) then |
---|
| 3193 | res@trXMinF = min((/miniwpptp,miniwspts,miniwpt/)) |
---|
[162] | 3194 | else |
---|
| 3195 | res@trXMinF = xs |
---|
| 3196 | end if |
---|
[190] | 3197 | if (xe .EQ. -1) then |
---|
| 3198 | res@trXMaxF = max((/maxiwpptp,maxiwspts,maxiwpt/)) |
---|
[162] | 3199 | else |
---|
| 3200 | res@trXMaxF = xe |
---|
[190] | 3201 | end if |
---|
[250] | 3202 | if (vNam(varn) .EQ. "wspts")then |
---|
| 3203 | res@xyDashPattern = 1 |
---|
| 3204 | end if |
---|
| 3205 | if (vNam(varn) .EQ. "wpt")then |
---|
| 3206 | res@xyDashPattern = 2 |
---|
| 3207 | end if |
---|
[175] | 3208 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3209 | |
---|
| 3210 | ; *************************************************** |
---|
| 3211 | ; legend for combined plot |
---|
| 3212 | ; *************************************************** |
---|
| 3213 | |
---|
| 3214 | lgres = True |
---|
| 3215 | lgMonoDashIndex = False |
---|
| 3216 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3217 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3218 | lgres@vpWidthF = 0.09 |
---|
| 3219 | lgres@vpHeightF = 0.12 |
---|
[161] | 3220 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3221 | lbid = gsn_create_legend(wks,3,(/"wpptp","wspts","wpt"/),lgres) |
---|
| 3222 | |
---|
| 3223 | amres = True |
---|
| 3224 | amres@amParallelPosF = 0.65 |
---|
| 3225 | amres@amOrthogonalPosF = -0.2 |
---|
| 3226 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3227 | overlay(plot(n),plot_wpptp) |
---|
| 3228 | wpptp=1 |
---|
| 3229 | else |
---|
[174] | 3230 | if (prof3d .EQ. 0)then |
---|
| 3231 | varn=varn+1 |
---|
| 3232 | end if |
---|
[161] | 3233 | continue |
---|
| 3234 | end if |
---|
| 3235 | end if |
---|
| 3236 | if (vNam(varn) .EQ. "wsptsBC" .OR. vNam(varn) .EQ. "wptBC") then |
---|
| 3237 | if (wsptsBC .EQ. 0) then |
---|
| 3238 | res@gsnLeftString = "wsptsBC and wptBC" |
---|
[218] | 3239 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3240 | res@gsnRightString = " " |
---|
[190] | 3241 | if (xs .EQ. -1) then |
---|
| 3242 | res@trXMinF = min((/miniwsptsBC,miniwptBC/)) |
---|
[162] | 3243 | else |
---|
| 3244 | res@trXMinF = xs |
---|
| 3245 | end if |
---|
[190] | 3246 | if (xe .EQ. -1) then |
---|
| 3247 | res@trXMaxF = max((/maxiwsptsBC,maxiwptBC/)) |
---|
[162] | 3248 | else |
---|
| 3249 | res@trXMaxF = xe |
---|
[190] | 3250 | end if |
---|
[250] | 3251 | if (vNam(varn) .EQ. "wptBC")then |
---|
| 3252 | res@xyDashPattern = 1 |
---|
| 3253 | end if |
---|
[175] | 3254 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3255 | |
---|
| 3256 | ; *************************************************** |
---|
| 3257 | ; legend for combined plot |
---|
| 3258 | ; *************************************************** |
---|
| 3259 | |
---|
| 3260 | lgres = True |
---|
| 3261 | lgMonoDashIndex = False |
---|
| 3262 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3263 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3264 | lgres@vpWidthF = 0.1 |
---|
| 3265 | lgres@vpHeightF = 0.12 |
---|
[161] | 3266 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3267 | lbid = gsn_create_legend(wks,3,(/"wsptsBC","wptBC"/),lgres) |
---|
| 3268 | |
---|
| 3269 | amres = True |
---|
| 3270 | amres@amParallelPosF = 0.65 |
---|
| 3271 | amres@amOrthogonalPosF = -0.2 |
---|
| 3272 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3273 | overlay(plot(n),plot_wsptsBC) |
---|
| 3274 | wsptsBC=1 |
---|
| 3275 | else |
---|
[174] | 3276 | if (prof3d .EQ. 0)then |
---|
| 3277 | varn=varn+1 |
---|
| 3278 | end if |
---|
[161] | 3279 | continue |
---|
| 3280 | end if |
---|
| 3281 | end if |
---|
| 3282 | if (vNam(varn) .EQ. "wpvptp" .OR. vNam(varn) .EQ. "wsvpts" .OR. vNam(varn) .EQ. "wvpt") then |
---|
| 3283 | if (wpvptp .EQ. 0) then |
---|
[250] | 3284 | res@gsnLeftString = "wpvptp, wsvpts and wvpt" |
---|
[218] | 3285 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3286 | res@gsnRightString = " " |
---|
[190] | 3287 | if (xs .EQ. -1) then |
---|
| 3288 | res@trXMinF = min((/miniwpvptp,miniwsvpts,miniwvpt/)) |
---|
[162] | 3289 | else |
---|
| 3290 | res@trXMinF = xs |
---|
| 3291 | end if |
---|
[190] | 3292 | if (xe .EQ. -1) then |
---|
| 3293 | res@trXMaxF = max((/maxiwpvptp,maxiwsvpts,maxiwvpt/)) |
---|
[162] | 3294 | else |
---|
| 3295 | res@trXMaxF = xe |
---|
[190] | 3296 | end if |
---|
[250] | 3297 | if (vNam(varn) .EQ. "wsvpts")then |
---|
| 3298 | res@xyDashPattern = 1 |
---|
| 3299 | end if |
---|
| 3300 | if (vNam(varn) .EQ. "wvpt")then |
---|
| 3301 | res@xyDashPattern = 2 |
---|
| 3302 | end if |
---|
[175] | 3303 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3304 | |
---|
| 3305 | ; *************************************************** |
---|
| 3306 | ; legend for combined plot |
---|
| 3307 | ; *************************************************** |
---|
| 3308 | |
---|
| 3309 | lgres = True |
---|
| 3310 | lgMonoDashIndex = False |
---|
| 3311 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3312 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3313 | lgres@vpWidthF = 0.1 |
---|
| 3314 | lgres@vpHeightF = 0.12 |
---|
[161] | 3315 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3316 | lbid = gsn_create_legend(wks,3,(/"wpvptp","wsvpts","wvpt"/),lgres) |
---|
| 3317 | |
---|
| 3318 | amres = True |
---|
| 3319 | amres@amParallelPosF = 0.65 |
---|
| 3320 | amres@amOrthogonalPosF = -0.2 |
---|
| 3321 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3322 | overlay(plot(n),plot_wpvptp) |
---|
| 3323 | wpvptp=1 |
---|
| 3324 | else |
---|
[174] | 3325 | if (prof3d .EQ. 0)then |
---|
| 3326 | varn=varn+1 |
---|
| 3327 | end if |
---|
[161] | 3328 | continue |
---|
| 3329 | end if |
---|
| 3330 | end if |
---|
| 3331 | if (vNam(varn) .EQ. "wpqp" .OR. vNam(varn) .EQ. "wsqs" .OR. vNam(varn) .EQ. "wq") then |
---|
| 3332 | if (wpqp .EQ. 0) then |
---|
| 3333 | res@gsnLeftString = "wpqp, wsqs and wq" |
---|
[218] | 3334 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3335 | res@gsnRightString = " " |
---|
[190] | 3336 | if (xs .EQ. -1) then |
---|
| 3337 | res@trXMinF = min((/miniwpqp,miniwsqs,miniwq/)) |
---|
[162] | 3338 | else |
---|
| 3339 | res@trXMinF = xs |
---|
| 3340 | end if |
---|
[190] | 3341 | if (xe .EQ. -1) then |
---|
| 3342 | res@trXMaxF = max((/maxiwpqp,maxiwsqs,maxiwq/)) |
---|
[162] | 3343 | else |
---|
| 3344 | res@trXMaxF = xe |
---|
[190] | 3345 | end if |
---|
[250] | 3346 | if (vNam(varn) .EQ. "wsqs")then |
---|
| 3347 | res@xyDashPattern = 1 |
---|
| 3348 | end if |
---|
| 3349 | if (vNam(varn) .EQ. "wq")then |
---|
| 3350 | res@xyDashPattern = 2 |
---|
| 3351 | end if |
---|
[175] | 3352 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3353 | |
---|
| 3354 | ; *************************************************** |
---|
| 3355 | ; legend for combined plot |
---|
| 3356 | ; *************************************************** |
---|
| 3357 | |
---|
| 3358 | lgres = True |
---|
| 3359 | lgMonoDashIndex = False |
---|
| 3360 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3361 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3362 | lgres@vpWidthF = 0.08 |
---|
| 3363 | lgres@vpHeightF = 0.12 |
---|
[161] | 3364 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3365 | lbid = gsn_create_legend(wks,3,(/"wpqp","wsqs","wq"/),lgres) |
---|
| 3366 | |
---|
| 3367 | amres = True |
---|
| 3368 | amres@amParallelPosF = 0.65 |
---|
| 3369 | amres@amOrthogonalPosF = -0.2 |
---|
| 3370 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3371 | overlay(plot(n),plot_wpqp) |
---|
| 3372 | wpqp=1 |
---|
| 3373 | else |
---|
[174] | 3374 | if (prof3d .EQ. 0)then |
---|
| 3375 | varn=varn+1 |
---|
| 3376 | end if |
---|
[161] | 3377 | continue |
---|
| 3378 | end if |
---|
| 3379 | end if |
---|
| 3380 | if (vNam(varn) .EQ. "wpqvp" .OR. vNam(varn) .EQ. "wsqvs" .OR. vNam(varn) .EQ. "wqv") then |
---|
| 3381 | if (wpqvp .EQ. 0) then |
---|
| 3382 | res@gsnLeftString = "wpqvp, wsqvs and wqv" |
---|
[218] | 3383 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3384 | res@gsnRightString = " " |
---|
[190] | 3385 | if (xs .EQ. -1) then |
---|
| 3386 | res@trXMinF = min((/miniwpqp,miniwsqvs,miniwqv/)) |
---|
[162] | 3387 | else |
---|
| 3388 | res@trXMinF = xs |
---|
| 3389 | end if |
---|
[190] | 3390 | if (xe .EQ. -1) then |
---|
| 3391 | res@trXMaxF = max((/maxiwpqp,maxiwsqvs,maxiwqv/)) |
---|
[162] | 3392 | else |
---|
| 3393 | res@trXMaxF = xe |
---|
[190] | 3394 | end if |
---|
[250] | 3395 | if (vNam(varn) .EQ. "wsqvs")then |
---|
| 3396 | res@xyDashPattern = 1 |
---|
| 3397 | end if |
---|
| 3398 | if (vNam(varn) .EQ. "wqv")then |
---|
| 3399 | res@xyDashPattern = 2 |
---|
| 3400 | end if |
---|
[175] | 3401 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3402 | |
---|
| 3403 | ; *************************************************** |
---|
| 3404 | ; legend for combined plot |
---|
| 3405 | ; *************************************************** |
---|
| 3406 | |
---|
| 3407 | lgres = True |
---|
| 3408 | lgMonoDashIndex = False |
---|
| 3409 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3410 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3411 | lgres@vpWidthF = 0.09 |
---|
| 3412 | lgres@vpHeightF = 0.12 |
---|
[161] | 3413 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3414 | lbid = gsn_create_legend(wks,3,(/"wpqvp","wsqvs","wqv"/),lgres) |
---|
| 3415 | |
---|
| 3416 | amres = True |
---|
| 3417 | amres@amParallelPosF = 0.65 |
---|
| 3418 | amres@amOrthogonalPosF = -0.2 |
---|
| 3419 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3420 | overlay(plot(n),plot_wpqvp) |
---|
| 3421 | wpqvp=1 |
---|
| 3422 | else |
---|
[174] | 3423 | if (prof3d .EQ. 0)then |
---|
| 3424 | varn=varn+1 |
---|
| 3425 | end if |
---|
[161] | 3426 | continue |
---|
| 3427 | end if |
---|
| 3428 | end if |
---|
| 3429 | if (vNam(varn) .EQ. "wpsp" .OR. vNam(varn) .EQ. "wsss" .OR. vNam(varn) .EQ. "ws") then |
---|
| 3430 | if (wpsp .EQ. 0) then |
---|
| 3431 | res@gsnLeftString = "wpsp, wsss and ws" |
---|
[218] | 3432 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3433 | res@gsnRightString = " " |
---|
[190] | 3434 | if (xs .EQ. -1) then |
---|
| 3435 | res@trXMinF = min((/miniwpsp,miniwsss,miniws/)) |
---|
[162] | 3436 | else |
---|
| 3437 | res@trXMinF = xs |
---|
| 3438 | end if |
---|
[190] | 3439 | if (xe .EQ. -1) then |
---|
| 3440 | res@trXMaxF = max((/maxiwpsp,maxiwsss,maxiws/)) |
---|
[162] | 3441 | else |
---|
| 3442 | res@trXMaxF = xe |
---|
[190] | 3443 | end if |
---|
[250] | 3444 | if (vNam(varn) .EQ. "wsss")then |
---|
| 3445 | res@xyDashPattern = 1 |
---|
| 3446 | end if |
---|
| 3447 | if (vNam(varn) .EQ. "ws")then |
---|
| 3448 | res@xyDashPattern = 2 |
---|
| 3449 | end if |
---|
[175] | 3450 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3451 | |
---|
| 3452 | ; *************************************************** |
---|
| 3453 | ; legend for combined plot |
---|
| 3454 | ; *************************************************** |
---|
| 3455 | |
---|
| 3456 | lgres = True |
---|
| 3457 | lgMonoDashIndex = False |
---|
| 3458 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3459 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3460 | lgres@vpWidthF = 0.08 |
---|
| 3461 | lgres@vpHeightF = 0.12 |
---|
[161] | 3462 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3463 | lbid = gsn_create_legend(wks,3,(/"wpsp","wsss","ws"/),lgres) |
---|
| 3464 | |
---|
| 3465 | amres = True |
---|
| 3466 | amres@amParallelPosF = 0.65 |
---|
| 3467 | amres@amOrthogonalPosF = -0.2 |
---|
| 3468 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3469 | overlay(plot(n),plot_wpsp) |
---|
| 3470 | wpsp=1 |
---|
| 3471 | else |
---|
[174] | 3472 | if (prof3d .EQ. 0)then |
---|
| 3473 | varn=varn+1 |
---|
| 3474 | end if |
---|
[161] | 3475 | continue |
---|
| 3476 | end if |
---|
| 3477 | end if |
---|
| 3478 | if (vNam(varn) .EQ. "wpsap" .OR.vNam(varn) .EQ. "wssas" .OR. vNam(varn) .EQ. "wsa") then |
---|
| 3479 | if (wpsap .EQ. 0) then |
---|
| 3480 | res@gsnLeftString = "wpsap, wssas and wsa" |
---|
[218] | 3481 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3482 | res@gsnRightString = " " |
---|
[190] | 3483 | if (xs .EQ. -1) then |
---|
| 3484 | res@trXMinF = min((/miniwpsap,miniwssas,miniwsa/)) |
---|
[162] | 3485 | else |
---|
| 3486 | res@trXMinF = xs |
---|
| 3487 | end if |
---|
[190] | 3488 | if (xe .EQ. -1) then |
---|
| 3489 | res@trXMaxF = max((/maxiwpsap,maxiwssas,maxiwsa/)) |
---|
[162] | 3490 | else |
---|
| 3491 | res@trXMaxF = xe |
---|
[190] | 3492 | end if |
---|
[250] | 3493 | if (vNam(varn) .EQ. "wssas")then |
---|
| 3494 | res@xyDashPattern = 1 |
---|
| 3495 | end if |
---|
| 3496 | if (vNam(varn) .EQ. "wsa")then |
---|
| 3497 | res@xyDashPattern = 2 |
---|
| 3498 | end if |
---|
[175] | 3499 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3500 | |
---|
| 3501 | ; *************************************************** |
---|
| 3502 | ; legend for combined plot |
---|
| 3503 | ; *************************************************** |
---|
| 3504 | |
---|
| 3505 | lgres = True |
---|
| 3506 | lgMonoDashIndex = False |
---|
| 3507 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3508 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3509 | lgres@vpWidthF = 0.09 |
---|
| 3510 | lgres@vpHeightF = 0.12 |
---|
[161] | 3511 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3512 | lbid = gsn_create_legend(wks,3,(/"wpsap","wssas","wsa"/),lgres) |
---|
| 3513 | |
---|
| 3514 | amres = True |
---|
| 3515 | amres@amParallelPosF = 0.65 |
---|
| 3516 | amres@amOrthogonalPosF = -0.2 |
---|
| 3517 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3518 | overlay(plot(n),plot_wpsap) |
---|
| 3519 | wpsap=1 |
---|
| 3520 | else |
---|
[174] | 3521 | if (prof3d .EQ. 0)then |
---|
| 3522 | varn=varn+1 |
---|
| 3523 | end if |
---|
[161] | 3524 | continue |
---|
| 3525 | end if |
---|
| 3526 | end if |
---|
[162] | 3527 | |
---|
[161] | 3528 | if (vNam(varn) .EQ. "us2" .OR. vNam(varn) .EQ. "vs2" .OR. vNam(varn) .EQ. "ws2") then |
---|
| 3529 | if (us2 .EQ. 0) then |
---|
| 3530 | res@gsnLeftString = "us2, vs2 and ws2" |
---|
[218] | 3531 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3532 | res@gsnRightString = " " |
---|
[190] | 3533 | if (xs .EQ. -1) then |
---|
| 3534 | res@trXMinF = min((/minius2,minivs2,miniws2/)) |
---|
[162] | 3535 | else |
---|
| 3536 | res@trXMinF = xs |
---|
| 3537 | end if |
---|
[190] | 3538 | if (xe .EQ. -1) then |
---|
| 3539 | res@trXMaxF = max((/maxius2,maxivs2,maxiws2/)) |
---|
| 3540 | else |
---|
[162] | 3541 | res@trXMaxF = xe |
---|
[190] | 3542 | end if |
---|
[250] | 3543 | if (vNam(varn) .EQ. "vs2")then |
---|
| 3544 | res@xyDashPattern = 1 |
---|
| 3545 | end if |
---|
| 3546 | if (vNam(varn) .EQ. "ws2")then |
---|
| 3547 | res@xyDashPattern = 2 |
---|
| 3548 | end if |
---|
[175] | 3549 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3550 | |
---|
| 3551 | ; *************************************************** |
---|
| 3552 | ; legend for combined plot |
---|
| 3553 | ; *************************************************** |
---|
| 3554 | |
---|
| 3555 | lgres = True |
---|
| 3556 | lgMonoDashIndex = False |
---|
| 3557 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3558 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[250] | 3559 | lgres@vpWidthF = 0.07 |
---|
| 3560 | lgres@vpHeightF = 0.12 |
---|
[161] | 3561 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3562 | lbid = gsn_create_legend(wks,3,(/"us2","vs2","ws2"/),lgres) |
---|
| 3563 | |
---|
| 3564 | amres = True |
---|
| 3565 | amres@amParallelPosF = 0.65 |
---|
| 3566 | amres@amOrthogonalPosF = -0.2 |
---|
| 3567 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3568 | overlay(plot(n),plot_us2) |
---|
| 3569 | us2=1 |
---|
| 3570 | else |
---|
[174] | 3571 | if (prof3d .EQ. 0)then |
---|
| 3572 | varn=varn+1 |
---|
| 3573 | end if |
---|
[161] | 3574 | continue |
---|
| 3575 | end if |
---|
| 3576 | end if |
---|
[162] | 3577 | |
---|
[161] | 3578 | if (vNam(varn) .EQ. "wsususodz" .OR. vNam(varn) .EQ. "wspsodz" .OR. vNam(varn) .EQ. "wpeodz" ) then |
---|
| 3579 | if (wsususodz .EQ. 0) then |
---|
[250] | 3580 | res@gsnLeftString = "wsususodz, wspsodz and wpeodz" |
---|
[218] | 3581 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3582 | res@gsnRightString = " " |
---|
[190] | 3583 | if (xs .EQ. -1) then |
---|
| 3584 | res@trXMinF = min((/miniwsususodz,miniwspsodz,miniwpeodz/)) |
---|
[162] | 3585 | else |
---|
| 3586 | res@trXMinF = xs |
---|
| 3587 | end if |
---|
[190] | 3588 | if (xe .EQ. -1) then |
---|
| 3589 | res@trXMaxF = max((/maxiwsususodz,maxiwspsodz,maxiwpeodz/)) |
---|
[162] | 3590 | else |
---|
| 3591 | res@trXMaxF = xe |
---|
[190] | 3592 | end if |
---|
[250] | 3593 | if (vNam(varn) .EQ. "wspsodz")then |
---|
| 3594 | res@xyDashPattern = 1 |
---|
| 3595 | end if |
---|
| 3596 | if (vNam(varn) .EQ. "wpeodz")then |
---|
| 3597 | res@xyDashPattern = 2 |
---|
| 3598 | end if |
---|
[175] | 3599 | plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
[161] | 3600 | |
---|
| 3601 | ; *************************************************** |
---|
| 3602 | ; legend for combined plot |
---|
| 3603 | ; *************************************************** |
---|
| 3604 | |
---|
| 3605 | lgres = True |
---|
| 3606 | lgMonoDashIndex = False |
---|
| 3607 | lgres@lgLabelFont = "helvetica" |
---|
[250] | 3608 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[161] | 3609 | lgres@vpWidthF = 0.12 |
---|
[250] | 3610 | lgres@vpHeightF = 0.12 |
---|
[161] | 3611 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3612 | lbid = gsn_create_legend(wks,3,(/"wsususodz","wspsodz","wpeodz"/),lgres) |
---|
| 3613 | |
---|
| 3614 | amres = True |
---|
| 3615 | amres@amParallelPosF = 0.65 |
---|
| 3616 | amres@amOrthogonalPosF = -0.2 |
---|
| 3617 | annoid1 = gsn_add_annotation(plot(n),lbid,amres) |
---|
| 3618 | overlay(plot(n),plot_wsususodz) |
---|
| 3619 | wsususodz=1 |
---|
| 3620 | else |
---|
[174] | 3621 | if (prof3d .EQ. 0)then |
---|
| 3622 | varn=varn+1 |
---|
| 3623 | end if |
---|
[161] | 3624 | continue |
---|
| 3625 | end if |
---|
| 3626 | end if |
---|
[174] | 3627 | n=n+1 |
---|
| 3628 | if (prof3d .EQ. 0)then |
---|
| 3629 | varn=varn+1 |
---|
| 3630 | end if |
---|
[161] | 3631 | end if |
---|
| 3632 | end do |
---|
[190] | 3633 | end if |
---|
| 3634 | |
---|
| 3635 | com_var_avail=new(count_var,string) |
---|
[161] | 3636 | |
---|
[154] | 3637 | if (combine .EQ. 1) then |
---|
[174] | 3638 | co=0 |
---|
[161] | 3639 | n_o=0 |
---|
[174] | 3640 | do varn = 0,dim-1 |
---|
| 3641 | |
---|
| 3642 | check = True |
---|
| 3643 | |
---|
| 3644 | if (prof3d .EQ. 0) then |
---|
| 3645 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then |
---|
| 3646 | check = False |
---|
| 3647 | end if |
---|
[161] | 3648 | else |
---|
[174] | 3649 | if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "zusi") .OR. isStrSubset( vNam(varn), "zwwi") .OR. isStrSubset( vNam(varn), "x") .OR. isStrSubset( vNam(varn), "xu") .OR. isStrSubset( vNam(varn), "y") .OR. isStrSubset( vNam(varn), "yv") .OR. isStrSubset( vNam(varn), "zu_3d") .OR. isStrSubset( vNam(varn), "zw_3d")) then |
---|
| 3650 | check = False |
---|
| 3651 | end if |
---|
| 3652 | end if |
---|
| 3653 | |
---|
[190] | 3654 | if (var .NE. "all") then |
---|
[174] | 3655 | check = isStrSubset( var,","+vNam(varn)+"," ) |
---|
| 3656 | end if |
---|
| 3657 | |
---|
[175] | 3658 | if (check)then |
---|
| 3659 | |
---|
| 3660 | if (prof3d .EQ. 0) then |
---|
[218] | 3661 | if (log_z .EQ. 1) then |
---|
[250] | 3662 | z = f_att->$vNam(varn+1)$(1:dimz-1) |
---|
[175] | 3663 | else |
---|
[250] | 3664 | z = f_att->$vNam(varn+1)$ |
---|
[175] | 3665 | end if |
---|
| 3666 | else |
---|
| 3667 | do i=0,b-1 |
---|
| 3668 | if (isStrSubset( a(i),"zu_3d" ))then |
---|
| 3669 | z_v(varn,:) = z_u |
---|
[218] | 3670 | if (log_z .EQ. 1) then |
---|
[175] | 3671 | z = z_v(varn,1:dimz-1) |
---|
| 3672 | else |
---|
| 3673 | z = z_v(varn,:) |
---|
| 3674 | end if |
---|
| 3675 | else |
---|
| 3676 | if (isStrSubset( a(i),"zw_3d" ))then |
---|
| 3677 | z_v(varn,:) = z_w |
---|
[218] | 3678 | if (log_z .EQ. 1) then |
---|
[175] | 3679 | z = z_v(varn,1:dimz-1) |
---|
| 3680 | else |
---|
| 3681 | z = z_v(varn,:) |
---|
| 3682 | end if |
---|
| 3683 | end if |
---|
| 3684 | end if |
---|
| 3685 | end do |
---|
| 3686 | end if |
---|
[174] | 3687 | |
---|
[218] | 3688 | z=z/norm_z |
---|
[190] | 3689 | |
---|
| 3690 | com_var_avail(n_o)=vNam(varn) |
---|
| 3691 | |
---|
[161] | 3692 | com=isStrSubset( c_var,","+vNam(varn)+"," ) |
---|
[174] | 3693 | |
---|
[175] | 3694 | if (com)then |
---|
[174] | 3695 | co = co+1 |
---|
[161] | 3696 | if (n_o .EQ. 1) then |
---|
[175] | 3697 | res@xyDashPattern = 1 |
---|
[161] | 3698 | else |
---|
| 3699 | if (n_o .EQ. 2) then |
---|
| 3700 | res@xyDashPattern = 2 |
---|
| 3701 | else |
---|
| 3702 | res@xyDashPattern = 0 |
---|
[175] | 3703 | res@gsnLeftString = "Combined Plot of "+c_var |
---|
[218] | 3704 | res@tiXAxisString = "["+unit(varn)+"]" |
---|
| 3705 | res@gsnRightString = " " |
---|
[190] | 3706 | if (xs .EQ. -1) then |
---|
| 3707 | res@trXMinF = min(mini) |
---|
[162] | 3708 | else |
---|
| 3709 | res@trXMinF = xs |
---|
| 3710 | end if |
---|
[190] | 3711 | if (xe .EQ. -1) then |
---|
| 3712 | res@trXMaxF = max(maxi) |
---|
[162] | 3713 | else |
---|
| 3714 | res@trXMaxF = xe |
---|
| 3715 | end if |
---|
[161] | 3716 | end if |
---|
| 3717 | end if |
---|
| 3718 | label(n_o)=vNam(varn) |
---|
| 3719 | color_o(n_o)=237 |
---|
| 3720 | plot_o(n_o)=gsn_csm_xy(wks,data(varn,:,:),z,res) |
---|
| 3721 | n_o=n_o+1 |
---|
[174] | 3722 | end if |
---|
| 3723 | if (prof3d .EQ. 0)then |
---|
| 3724 | varn=varn+1 |
---|
| 3725 | end if |
---|
[161] | 3726 | end if |
---|
| 3727 | end do |
---|
| 3728 | |
---|
| 3729 | if(number_comb .EQ. 2)then |
---|
[174] | 3730 | if (co .EQ. 2)then |
---|
| 3731 | overlay(plot_o(0),plot_o(1)) |
---|
| 3732 | else |
---|
[190] | 3733 | print(" ") |
---|
| 3734 | print("combining is not possible,") |
---|
| 3735 | print("'c_var'(= "+c_var+") must include two variables of the general plots = ") |
---|
| 3736 | print("- "+com_var_avail) |
---|
| 3737 | print("be sure to have one comma berfore and after the variable") |
---|
| 3738 | print(" ") |
---|
| 3739 | exit |
---|
[174] | 3740 | end if |
---|
[161] | 3741 | end if |
---|
| 3742 | if(number_comb .EQ. 3)then |
---|
[174] | 3743 | if (co .EQ. 3)then |
---|
| 3744 | overlay(plot_o(0),plot_o(1)) |
---|
| 3745 | overlay(plot_o(0),plot_o(2)) |
---|
| 3746 | else |
---|
[190] | 3747 | print(" ") |
---|
| 3748 | print("combining is not possible,") |
---|
| 3749 | print("'c_var'(= "+c_var+") must include three variables of the general plots = ") |
---|
| 3750 | print("- "+com_var_avail) |
---|
| 3751 | print("be sure to have one comma berfore and after the variable") |
---|
| 3752 | print(" ") |
---|
| 3753 | exit |
---|
[174] | 3754 | end if |
---|
[161] | 3755 | end if |
---|
[154] | 3756 | |
---|
[161] | 3757 | ; *************************************************** |
---|
| 3758 | ; legend for combined plot |
---|
| 3759 | ; *************************************************** |
---|
[154] | 3760 | |
---|
[161] | 3761 | lgres = True |
---|
| 3762 | lgMonoDashIndex = False |
---|
| 3763 | lgres@lgDashIndexes = (/0,1,2/) |
---|
| 3764 | lgres@lgLabelFont = "helvetica" |
---|
[218] | 3765 | lgres@lgLabelFontHeightF = font_size_legend |
---|
[161] | 3766 | lgres@vpWidthF = 0.12 |
---|
| 3767 | lgres@vpHeightF = 0.1 |
---|
| 3768 | |
---|
| 3769 | lbid = gsn_create_legend(wks,number_comb,label,lgres) |
---|
| 3770 | |
---|
| 3771 | amres = True |
---|
| 3772 | amres@amParallelPosF = 0.65 |
---|
| 3773 | amres@amOrthogonalPosF = -0.2 |
---|
| 3774 | annoid1 = gsn_add_annotation(plot_o(0),lbid,amres) |
---|
| 3775 | |
---|
| 3776 | plot(0) = plot_o(0) |
---|
| 3777 | |
---|
[154] | 3778 | end if |
---|
| 3779 | |
---|
| 3780 | ; *************************************************** |
---|
| 3781 | ; merge plots onto one page |
---|
| 3782 | ; *************************************************** |
---|
[162] | 3783 | |
---|
[161] | 3784 | do m=0,n-1 |
---|
| 3785 | plot_(m)=plot(n-1-m) |
---|
[154] | 3786 | end do |
---|
| 3787 | |
---|
[161] | 3788 | if (format_out .EQ. "eps" .OR. format_out .EQ. "epsi") then |
---|
[175] | 3789 | gsn_panel(wks,plot_,(/n,1/),resP) |
---|
[250] | 3790 | print(" ") |
---|
| 3791 | print("Outputs to .eps or .epsi have only one frame") |
---|
| 3792 | print(" ") |
---|
[161] | 3793 | else |
---|
[218] | 3794 | do i = 0,n-1, no_rows*no_columns |
---|
| 3795 | if( (i+no_rows*no_columns) .gt. (n-1)) then |
---|
| 3796 | gsn_panel(wks,plot_(i:n-1),(/no_rows,no_columns/),resP) |
---|
[161] | 3797 | else |
---|
[250] | 3798 | gsn_panel(wks,plot_(i:i+no_rows*no_columns-1),(/no_rows,no_columns/),resP) |
---|
[161] | 3799 | end if |
---|
| 3800 | end do |
---|
| 3801 | end if |
---|
| 3802 | |
---|
[154] | 3803 | print(" ") |
---|
| 3804 | print("Output to: " + file_out +"."+ format_out) |
---|
| 3805 | print(" ") |
---|
| 3806 | |
---|
| 3807 | end |
---|