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