Changeset 566 for palm/trunk/SCRIPTS/NCL/profiles.ncl
- Timestamp:
- Sep 30, 2010 1:37:58 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SCRIPTS/NCL/profiles.ncl
r534 r566 24 24 print("Neither the personal configuration file '.ncl.config' exists in") 25 25 print("~/palm/current_version") 26 print("nor the default configuration file '.ncl.config.default' exists in") 26 print("nor the default configuration file '.ncl.config.default' "+\ 27 "exists in") 27 28 print(palm_bin_path + "/NCL") 28 29 print(" ") … … 60 61 file_in = new(no_files,string) 61 62 file_in_1 = new(no_files,logical) 62 start_f 63 end_f 63 start_f_t = new(no_files,integer) 64 end_f_t = new(no_files,integer) 64 65 65 66 if (file_1 .EQ. "File in") then … … 73 74 file_in_1(0) = False 74 75 if (isStrSubset(file_in(0), ".nc"))then 75 start_f _1= -276 end_f _1= -276 start_f = -2 77 end_f = -2 77 78 file_in_1(0) = True 78 79 end if 79 if (start_f_1 .EQ. -1)then 80 print(" ") 81 print("'start_f_1' must be one of the cyclic numbers (at least 0) of your input file(s)") 80 if (start_f .EQ. -1)then 81 print(" ") 82 print("'start_f' must be one of the cyclic numbers (at least 0) "+\ 83 "of your input file(s)") 82 84 print(" ") 83 85 exit 84 86 end if 85 if (end_f_1 .EQ. -1)then 86 print(" ") 87 print("'end_f_1' must be one of the cyclic numbers (at least 0) of your input file(s)") 87 if (end_f .EQ. -1)then 88 print(" ") 89 print("'end_f' must be one of the cyclic numbers (at least 0) of "+\ 90 "your input file(s)") 88 91 print(" ") 89 92 exit 90 93 end if 91 start_f (0) = start_f_192 end_f (0) = end_f_194 start_f_t(0) = start_f 95 end_f_t(0) = end_f 93 96 94 97 if (no_files .GT. 1) then … … 109 112 if (start_f_2 .EQ. -1)then 110 113 print(" ") 111 print("'start_f_2' must be one of the cyclic numbers (at least 0) of your input file(s)") 114 print("'start_f_2' must be one of the cyclic numbers (at least 0) "+\ 115 "of your input file(s)") 112 116 print(" ") 113 117 exit … … 115 119 if (end_f_2 .EQ. -1)then 116 120 print(" ") 117 print("'end_f_2' must be one of the cyclic numbers (at least 0) of your input file(s)") 121 print("'end_f_2' must be one of the cyclic numbers (at least 0) "+\ 122 "of your input file(s)") 118 123 print(" ") 119 124 exit … … 140 145 if (start_f_3 .EQ. -1)then 141 146 print(" ") 142 print("'start_f_3' must be one of the cyclic numbers (at least 0) of your input file(s)") 147 print("'start_f_3' must be one of the cyclic numbers (at least 0) "+\ 148 "of your input file(s)") 143 149 print(" ") 144 150 exit … … 146 152 if (end_f_3 .EQ. -1)then 147 153 print(" ") 148 print("'end_f_3' must be one of the cyclic numbers (at least 0) of your input file(s)") 154 print("'end_f_3' must be one of the cyclic numbers (at least 0) "+\ 155 "of your input file(s)") 149 156 print(" ") 150 157 exit … … 171 178 if (start_f_4 .EQ. -1)then 172 179 print(" ") 173 print("'start_f_4' must be one of the cyclic numbers (at least 0) of your input file(s)") 180 print("'start_f_4' must be one of the cyclic numbers (at least 0) "+\ 181 "of your input file(s)") 174 182 print(" ") 175 183 exit … … 177 185 if (end_f_4 .EQ. -1)then 178 186 print(" ") 179 print("'end_f_4' must be one of the cyclic numbers (at least 0) of your input file(s)") 187 print("'end_f_4' must be one of the cyclic numbers (at least 0) "+\ 188 "of your input file(s)") 180 189 print(" ") 181 190 exit … … 202 211 if (start_f_5 .EQ. -1)then 203 212 print(" ") 204 print("'start_f_5' must be one of the cyclic numbers (at least 0) of your input file(s)") 213 print("'start_f_5' must be one of the cyclic numbers (at least 0) "+\ 214 "of your input file(s)") 205 215 print(" ") 206 216 exit … … 208 218 if (end_f_5 .EQ. -1)then 209 219 print(" ") 210 print("'end_f_5' must be one of the cyclic numbers (at least 0) of your input file(s)") 220 print("'end_f_5' must be one of the cyclic numbers (at least 0) "+\ 221 "of your input file(s)") 211 222 print(" ") 212 223 exit … … 233 244 if (start_f_6 .EQ. -1)then 234 245 print(" ") 235 print("'start_f_6' must be one of the cyclic numbers (at least 0) of your input file(s)") 246 print("'start_f_6' must be one of the cyclic numbers (at least 0) "+\ 247 "of your input file(s)") 236 248 print(" ") 237 249 exit … … 239 251 if (end_f_6 .EQ. -1)then 240 252 print(" ") 241 print("'end_f_6' must be one of the cyclic numbers (at least 0) of your input file(s)") 253 print("'end_f_6' must be one of the cyclic numbers (at least 0) "+\ 254 "of your input file(s)") 242 255 print(" ") 243 256 exit … … 248 261 249 262 250 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" .AND. format_out .NE. "png")then 263 if (format_out .NE. "x11" .AND. format_out .NE. "pdf" .AND. \ 264 format_out .NE. "eps" .AND. format_out .NE. "ps" .AND. \ 265 format_out .NE. "epsi" .AND. format_out .NE. "ncgm" .AND. \ 266 format_out .NE. "png")then 251 267 print(" ") 252 268 print("'format_out = "+format_out+"' is invalid and set to'x11'") … … 273 289 over = 0 274 290 print(" ") 275 print("If you have more than one input file - you cannot overlay variables: over is set to 0") 291 print("If you have more than one input file - you cannot overlay "+\ 292 "variables: over is set to 0") 276 293 print(" ") 277 294 end if … … 286 303 combine = 0 287 304 print(" ") 288 print("If you have more than one input file you cannot combine variables: combine is set to 0") 305 print("If you have more than one input file you cannot combine "+\ 306 "variables: combine is set to 0") 289 307 print(" ") 290 308 end if … … 336 354 do nof=0,no_files-1 337 355 338 files=new(end_f (nof)-start_f(nof)+1,string)356 files=new(end_f_t(nof)-start_f_t(nof)+1,string) 339 357 if (file_in_1(nof))then 340 358 if (isfilepresent(file_in(nof)))then … … 347 365 end if 348 366 else 349 if (start_f (nof) .EQ. 0)then367 if (start_f_t(nof) .EQ. 0)then 350 368 if (isfilepresent(file_in(nof)+".nc"))then 351 369 files(0)=file_in(nof)+".nc" 352 do i=1,end_f (nof)370 do i=1,end_f_t(nof) 353 371 if (isfilepresent(file_in(nof)+"."+i+".nc"))then 354 372 files(i)=file_in(nof)+"."+i+".nc" 355 373 else 356 374 print(" ") 357 print("Input file: '"+file_in(nof)+"."+i+".nc' does not exist") 375 print("Input file: '"+file_in(nof)+"."+i+".nc' does not "+\ 376 "exist") 358 377 print(" ") 359 378 exit … … 367 386 end if 368 387 else 369 do i=start_f (nof),end_f(nof)388 do i=start_f_t(nof),end_f_t(nof) 370 389 if (isfilepresent(file_in(nof)+"."+i+".nc"))then 371 files(i-start_f (nof))=file_in(nof)+"."+i+".nc"390 files(i-start_f_t(nof))=file_in(nof)+"."+i+".nc" 372 391 else 373 392 print(" ") … … 392 411 if (dim0 .NE. dim)then 393 412 print(" ") 394 print("There are 'no_files'="+no_files+" input files but they do not contain the same variables") 413 print("There are 'no_files'="+no_files+" input files but they do "+\ 414 "not contain the same variables") 395 415 print(" ") 396 416 exit … … 399 419 if (vNam0(i) .NE. vNam(i))then 400 420 print(" ") 401 print("There are 'no_files'="+no_files+" input files but they do not contain the same variables") 421 print("There are 'no_files'="+no_files+" input files but "+\ 422 "they do not contain the same variables") 402 423 print(" ") 403 424 exit … … 423 444 prof3d = 0 424 445 do varn = dim-1,0,1 425 if ( isStrSubset( vNam(varn), "zu_3d") .OR. isStrSubset( vNam(varn), "zw_3d")) then 446 if ( isStrSubset( vNam(varn), "zu_3d") .OR. \ 447 isStrSubset( vNam(varn), "zw_3d")) then 426 448 prof3d = 1 427 449 break … … 475 497 476 498 do j=0,comma-2 477 vNam_temp(j) = charactertostring(var_char(indices(j)+1:indices(j+1)-1)) 499 vNam_temp(j) = charactertostring(\ 500 var_char(indices(j)+1:indices(j+1)-1)) 478 501 end do 479 502 … … 548 571 end if 549 572 550 ;--------- --------------------------------------------below steps only for first file -> nof=0573 ;---------below steps only for first file -> nof=0 551 574 if (nof .EQ. 0) then 552 575 … … 564 587 565 588 do varn=0,dim-1 566 if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then 589 if ( isStrSubset( vNam(varn), "time") .OR. \ 590 isStrSubset( vNam(varn), "NORM")) then 567 591 continue 568 592 end if … … 616 640 break 617 641 else 618 if(vNam(varn) .EQ. "es" .OR. isStrSubset(vNam(varn), "es_")\619 642 if(vNam(varn) .EQ. "es" .OR. \ 643 isStrSubset(vNam(varn), "es_") .OR. vNam(varn) .EQ. "e*" .OR. isStrSubset(vNam(varn), "e*_"))then 620 644 z_u = f_att->$vNam(varn+1)$ 621 645 break … … 881 905 co=0 882 906 do varn=0,dim-1 883 if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then 907 if ( isStrSubset( vNam(varn), "time") .OR. \ 908 isStrSubset( vNam(varn), "NORM")) then 884 909 check = False 885 910 else … … 983 1008 if (start_time_step .GT. t_all(nt-1)/3600)then 984 1009 print(" ") 985 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") 1010 print("'start_time_step' = "+ start_time_step +"h is greater "+\ 1011 "than last time step = " \ 1012 + t_all(nt-1)+"s = "+t_all(nt-1)/3600+"h") 986 1013 print(" ") 987 1014 print("Select another 'start_time_step'") … … 991 1018 if (start_time_step .LT. t_all(0)/3600)then 992 1019 print(" ") 993 print("'start_time_step' = "+ start_time_step +"h is lower than first time step = " + t_all(0)+"s = "+t_all(0)/3600+"h") 1020 print("'start_time_step' = "+ start_time_step +"h is lower "+\ 1021 "than first time step = " + t_all(0)+"s = "+t_all(0)/3600+"h") 994 1022 print(" ") 995 1023 exit … … 998 1026 999 1027 do i=0,nt-1 1000 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 1028 if (start_time_step .GE. (t_all(i)-delta_t/2)/3600 .AND.\ 1029 start_time_step .LT. (t_all(i)+delta_t/2)/3600)then 1001 1030 st=i 1002 1031 break … … 1021 1050 if (end_time_step .GT. t_all(nt-1)/3600)then 1022 1051 print(" ") 1023 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") 1052 print("'end_time_step' = "+ end_time_step +"h is greater "+\ 1053 "than last time step = " +\ 1054 t_all(nt-1)+"s = "+t_all(nt-1)/3600+"h") 1024 1055 print(" ") 1025 1056 print("Select another 'end_time_step'") … … 1029 1060 if (end_time_step .LT. start_time_step/3600)then 1030 1061 print(" ") 1031 print("'end_time_step' = "+ end_time_step +"h is lower than 'start_time_step' = "+start_time_step+"h") 1062 print("'end_time_step' = "+ end_time_step +"h is lower "+\ 1063 "than 'start_time_step' = "+start_time_step+"h") 1032 1064 print(" ") 1033 1065 print("Select another 'start_time_step' or 'end_time_step'") … … 1038 1070 1039 1071 do i=0,nt-1 1040 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 1072 if (end_time_step .GE. (t_all(i)-delta_t/2)/3600 .AND.\ 1073 end_time_step .LT. (t_all(i)+delta_t/2)/3600)then 1041 1074 et=i 1042 1075 break … … 1072 1105 if (time_stride .GE. no_time) then 1073 1106 print(" ") 1074 print("'time_stride' is greater equal than number of available time steps,") 1107 print("'time_stride' is greater equal than number of available "+\ 1108 "time steps,") 1075 1109 print("=> 'time_stride' is set to 1") 1076 1110 time_stride = 1 1077 1111 end if 1078 1112 1079 ti_in = ispan(start_time_step,end_time_step,time_stride) ;ti_in contents the time indices to plot 1113 ti_in = ispan(start_time_step,end_time_step,time_stride) ;ti_in contents 1114 ;the time indices 1115 ;to plot 1080 1116 np = dimsizes(ti_in) 1081 1117 1082 1118 print(" ") 1083 print("Output of time steps from "+t_all(start_time_step)/3600+" h = "+t_all(start_time_step)+" s => index = "+start_time_step) 1084 print(" till "+t_all(ti_in(np-1))/3600+" h = "+t_all(ti_in(np-1))+" s => index = "+end_time_step) 1119 print("Output of time steps from "+t_all(start_time_step)/3600+\ 1120 " h = "+t_all(start_time_step)+" s => index = "+start_time_step) 1121 print(" till "+t_all(ti_in(np-1))/3600+" h = "\ 1122 +t_all(ti_in(np-1))+" s => index = "+end_time_step) 1085 1123 print(" with temporal stride = "+time_stride) 1086 1124 print(" ") … … 1091 1129 ; **************************************************** 1092 1130 1093 legend_label=new(np, double)1131 legend_label=new(np,string) 1094 1132 do p=0, np-1 1095 legend_label(p)= decimalPlaces(t_all(ti_in(p))/3600,3,True)1133 legend_label(p)=sprintf("%6.2f", t_all(ti_in(p))/3600) 1096 1134 end do 1097 1098 1135 1099 1136 ; *************************************************** … … 1150 1187 res@xyMonoDashPattern = True 1151 1188 print(" ") 1152 print("If you use more than one file, patterns for different timesteps cannot be used") 1189 print("If you use more than one file, patterns for different "+\ 1190 "timesteps cannot be used") 1153 1191 print(" ") 1154 1192 end if … … 1202 1240 if (min_z .GE. max(z_w) ) then 1203 1241 print(" ") 1204 print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_w)+")") 1242 print("Minimum of height ('min_z'="+min_z+") is greater "+\ 1243 "than available heights (="+max(z_w)+")") 1205 1244 print(" ") 1206 1245 exit … … 1209 1248 if (min_z .GE. max(z_u) ) then 1210 1249 print(" ") 1211 print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_u)+")") 1250 print("Minimum of height ('min_z'="+min_z+") is greater "+\ 1251 "than available heights (="+max(z_u)+")") 1212 1252 print(" ") 1213 1253 exit … … 1217 1257 if (min_z .LT. z_u(1) ) then 1218 1258 print(" ") 1219 print("Begin height 'min_z' at least at level k=1 (="+z_u(1)+"m) due to the logarithmic scale of the y-axis") 1259 print("Begin height 'min_z' at least at level k=1 (="+\ 1260 z_u(1)+"m) due to the logarithmic scale of the y-axis") 1220 1261 print(" ") 1221 1262 exit … … 1224 1265 if (min_z .LT. z_w(1) ) then 1225 1266 print(" ") 1226 print("Begin height 'min_z' at least at level k=1 (="+z_w(1)+"m) due to the logarithmic scale of the y-axis") 1267 print("Begin height 'min_z' at least at level k=1 (="+\ 1268 z_w(1)+"m) due to the logarithmic scale of the y-axis") 1227 1269 print(" ") 1228 1270 exit … … 1244 1286 if (min_z .GE. max(z_w) ) then 1245 1287 print(" ") 1246 print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_w)+")") 1288 print("Minimum of height ('min_z'="+min_z+") is greater than "+\ 1289 "available heights (="+max(z_w)+")") 1247 1290 print(" ") 1248 1291 exit … … 1254 1297 if (min_z .GE. max(z_u) ) then 1255 1298 print(" ") 1256 print("Minimum of height ('min_z'="+min_z+") is greater than available heights (="+max(z_u)+")") 1299 print("Minimum of height ('min_z'="+min_z+") is greater than "+\ 1300 "available heights (="+max(z_u)+")") 1257 1301 print(" ") 1258 1302 exit … … 1274 1318 if (max_z .GT. max(z_w) ) then 1275 1319 print(" ") 1276 print("Maximum of height ('max_z'="+max_z+") is greater than available heights (="+max(z_w)+")") 1320 print("Maximum of height ('max_z'="+max_z+") is greater than "+\ 1321 "available heights (="+max(z_w)+")") 1277 1322 print(" ") 1278 1323 exit … … 1359 1404 1360 1405 end if 1361 ;------- -----------------------------------------------above steps only for first file1406 ;-------above steps only for first file 1362 1407 1363 1408 ; *************************************************** … … 1535 1580 if (start_x .GT. dimx-1)then 1536 1581 print(" ") 1537 print("'start_x' is greater than available x-range and set to maximum of x-range (excluding ghostpoint)") 1582 print("'start_x' is greater than available x-range and set to "+\ 1583 "maximum of x-range (excluding ghostpoint)") 1538 1584 print(" ") 1539 1585 start_x=dimx-2 … … 1546 1592 if (end_x .GT. dimx-1)then 1547 1593 print(" ") 1548 print("'end_x' = "+end_x+" is greater than available x-range and set to maximum of x-range (excluding ghostpoint)") 1594 print("'end_x' = "+end_x+" is greater than available x-range and set "+\ 1595 "to maximum of x-range (excluding ghostpoint)") 1549 1596 print(" ") 1550 1597 end_x=dimx-2 … … 1552 1599 if (end_x .LT. start_x)then 1553 1600 print(" ") 1554 print("'end_x' = "+end_x+" is lower than 'start_x' = "+start_x+" and set to maximum of x-range (excluding ghostpoint)") 1601 print("'end_x' = "+end_x+" is lower than 'start_x' = "+start_x+\ 1602 " and set to maximum of x-range (excluding ghostpoint)") 1555 1603 print(" ") 1556 1604 end_x=dimx-2 … … 1564 1612 if (start_y .GT. dimy-1)then 1565 1613 print(" ") 1566 print("'start_y' is greater than available y-range and set to maximum of y-range (excluding ghostpoint)") 1614 print("'start_y' is greater than available y-range and set to "+\ 1615 "maximum of y-range (excluding ghostpoint)") 1567 1616 print(" ") 1568 1617 start_x=dimy-2 … … 1575 1624 if (end_y .GT. dimy-1)then 1576 1625 print(" ") 1577 print("'end_y' = "+end_y+" is greater than available y-range and set to maximum of y-range (excluding ghostpoint)") 1626 print("'end_y' = "+end_y+" is greater than available y-range and "+\ 1627 "set to maximum of y-range (excluding ghostpoint)") 1578 1628 print(" ") 1579 1629 end_x=dimy-2 … … 1581 1631 if (end_y .LT. start_y)then 1582 1632 print(" ") 1583 print("'end_y' = "+end_y+" is lower than 'start_y' = "+start_y+" and set to maximum of y-range (excluding ghostpoint)") 1633 print("'end_y' = "+end_y+" is lower than 'start_y' = "+start_y+\ 1634 " and set to maximum of y-range (excluding ghostpoint)") 1584 1635 print(" ") 1585 1636 end_y=dimy-2 … … 1603 1654 1604 1655 if (prof3d .EQ. 0) then 1605 if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then 1656 if ( isStrSubset( vNam(varn), "time") .OR. \ 1657 isStrSubset( vNam(varn), "NORM")) then 1606 1658 check = False 1607 1659 end if 1608 1660 else 1609 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 1661 if ( isStrSubset( vNam(varn), "time") .OR. \ 1662 isStrSubset( vNam(varn), "zusi") .OR. \ 1663 isStrSubset( vNam(varn), "zwwi") .OR. \ 1664 isStrSubset( vNam(varn), "x") .OR. \ 1665 isStrSubset( vNam(varn), "xu") .OR. \ 1666 isStrSubset( vNam(varn), "y") .OR. \ 1667 isStrSubset( vNam(varn), "yv") .OR. \ 1668 isStrSubset( vNam(varn), "zu_3d") .OR. \ 1669 isStrSubset( vNam(varn), "zw_3d")) then 1610 1670 check = False 1611 1671 end if … … 1637 1697 temp = f[:]->$vNam(varn)$ 1638 1698 temp_att = f_att->$vNam(varn)$ 1639 data_temp = temp(ti_in(j),i,start_y:end_y,start_x:end_x) 1640 data(varn,j,i-1) = dim_avg_Wrap(dim_avg_Wrap(data_temp)) 1699 data_temp = temp(ti_in(j),i,\ 1700 start_y:end_y,start_x:end_x) 1701 data(varn,j,i-1) = dim_avg_Wrap(\ 1702 dim_avg_Wrap(data_temp)) 1641 1703 end do 1642 1704 end do … … 1646 1708 temp = f[:]->$vNam(varn)$ 1647 1709 temp_att = f_att->$vNam(varn)$ 1648 data_temp = temp(ti_in(j),i,start_y:end_y,start_x:end_x) 1710 data_temp = temp(ti_in(j),i,\ 1711 start_y:end_y,start_x:end_x) 1649 1712 data(varn,j,i) = dim_avg_Wrap(dim_avg_Wrap(data_temp)) 1650 1713 end do … … 1658 1721 if (n_o .GT. number_comb-1) then 1659 1722 print(" ") 1660 print("Set 'number_comb' to the number of overlaying variables ('c_var' = "+c_var+")") 1723 print("Set 'number_comb' to the number of overlaying "+\ 1724 "variables ('c_var' = "+c_var+")") 1661 1725 print(" ") 1662 1726 exit … … 1666 1730 max_value = abs(0.01*max(data(varn,:,:))) 1667 1731 else 1668 if (abs(min(data(varn,:,:))) .LT. 0.01 .AND. abs(max(data(varn,:,:))) .GT. 0.01)then 1732 if (abs(min(data(varn,:,:))) .LT. 0.01 .AND. \ 1733 abs(max(data(varn,:,:))) .GT. 0.01)then 1669 1734 min_value = abs(0.1*max(data(varn,:,:))) 1670 1735 max_value = abs(0.1*max(data(varn,:,:))) 1671 1736 else 1672 if (abs(max(data(varn,:,:))) .LT. 0.01 .AND. abs(min(data(varn,:,:))) .GT. 0.01)then 1737 if (abs(max(data(varn,:,:))) .LT. 0.01 .AND. \ 1738 abs(min(data(varn,:,:))) .GT. 0.01)then 1673 1739 min_value = abs(0.1*min(data(varn,:,:))) 1674 1740 max_value = abs(0.1*min(data(varn,:,:))) … … 1679 1745 end if 1680 1746 end if 1681 if (min(data(varn,:,:)) .EQ. 0 .AND. max(data(varn,:,:)) .EQ. 0)then 1747 if (min(data(varn,:,:)) .EQ. 0 .AND. \ 1748 max(data(varn,:,:)) .EQ. 0)then 1682 1749 min_value = 0.1 1683 1750 max_value = 0.1 … … 1782 1849 if(max_z_int .eq. min_z_int) 1783 1850 print(" ") 1784 print("Please increase 'max_z' or decrease 'min_z' so that there are") 1851 print("Please increase 'max_z' or decrease 'min_z' so that "+\ 1852 "there are") 1785 1853 print("at least two layers for the z-axis to plot") 1786 1854 print(" ") … … 1843 1911 res@trYMaxF = max_z 1844 1912 if (xs .EQ. -1) then 1845 res@trXMinF = min(data(varn,:,min_z_int:max_z_int))-min_value 1913 res@trXMinF = min(data(varn,:,min_z_int:max_z_int))-\ 1914 min_value 1846 1915 else 1847 1916 res@trXMinF = xs 1848 1917 end if 1849 1918 if (xe .EQ. -1) then 1850 res@trXMaxF = max(data(varn,:,min_z_int:max_z_int))+max_value 1919 res@trXMaxF = max(data(varn,:,min_z_int:max_z_int))+\ 1920 max_value 1851 1921 else 1852 1922 res@trXMaxF = xe … … 2301 2371 end if 2302 2372 2303 if (vNam(varn) .EQ. "wpptp" .OR. vNam(varn) .EQ. "w"+dq+"pt"+dq) then 2373 if (vNam(varn) .EQ. "wpptp" .OR. vNam(varn) \ 2374 .EQ. "w"+dq+"pt"+dq) then 2304 2375 miniwpptp=min(data(varn,:,min_z_int:max_z_int))-min_value 2305 2376 maxiwpptp=max(data(varn,:,min_z_int:max_z_int))+max_value … … 2418 2489 end if 2419 2490 2420 if (vNam(varn) .EQ. "wpvptp" .OR. vNam(varn) .EQ. "w"+dq+"vpt"+dq) then 2491 if (vNam(varn) .EQ. "wpvptp" .OR. vNam(varn) \ 2492 .EQ. "w"+dq+"vpt"+dq) then 2421 2493 miniwpvptp=min(data(varn,:,min_z_int:max_z_int))-min_value 2422 2494 maxiwpvptp=max(data(varn,:,min_z_int:max_z_int))+max_value … … 2558 2630 end if 2559 2631 2560 if (vNam(varn) .EQ. "wpqvp" .OR. vNam(varn) .EQ. "w"+dq+"qv"+dq) then 2632 if (vNam(varn) .EQ. "wpqvp" .OR. \ 2633 vNam(varn) .EQ. "w"+dq+"qv"+dq) then 2561 2634 miniwpqvp=min(data(varn,:,min_z_int:max_z_int))-min_value 2562 2635 maxiwpqvp=max(data(varn,:,min_z_int:max_z_int))+max_value … … 2698 2771 end if 2699 2772 2700 if (vNam(varn) .EQ. "wpsap" .OR. vNam(varn) .EQ. "w"+dq+"sa"+dq) then 2773 if (vNam(varn) .EQ. "wpsap" .OR. \ 2774 vNam(varn) .EQ. "w"+dq+"sa"+dq) then 2701 2775 miniwpsap=min(data(varn,:,min_z_int:max_z_int))-min_value 2702 2776 maxiwpsap=max(data(varn,:,min_z_int:max_z_int))+max_value … … 2838 2912 end if 2839 2913 2840 if (vNam(varn) .EQ. "wsususodz" .OR. vNam(varn) .EQ. "w*u*u*:dz") then 2914 if (vNam(varn) .EQ. "wsususodz" .OR. \ 2915 vNam(varn) .EQ. "w*u*u*:dz") then 2841 2916 miniwsususodz=min(data(varn,:,min_z_int:max_z_int))-min_value 2842 2917 maxiwsususodz=max(data(varn,:,min_z_int:max_z_int))+max_value … … 2884 2959 end if 2885 2960 end if 2886 if (vNam(varn) .EQ. "wpeodz" .OR. vNam(varn) .EQ. "w"+dq+"p:dz") then 2961 if (vNam(varn) .EQ. "wpeodz" .OR. \ 2962 vNam(varn) .EQ. "w"+dq+"p:dz") then 2887 2963 miniwpeodz=min(data(varn,:,min_z_int:max_z_int))-min_value 2888 2964 maxiwpeodz=max(data(varn,:,min_z_int:max_z_int))+max_value … … 2935 3011 if (isStrSubset(data@long_name," SR " ) .and. over_remind) then 2936 3012 print(" ") 2937 print("If you have outputs of statistic regions you cannot overlay variables;") 3013 print("If you have outputs of statistic regions you cannot overlay "+\ 3014 "variables;") 2938 3015 print("'over' is set to 0" ) 2939 3016 print(" ") … … 2992 3069 lgres@vpHeightF = 0.03*no_files 2993 3070 lgres@lgDashIndexes = multi_dash(no_files-1:0) 2994 lbid = gsn_create_legend(wks,no_files,multi_legend(no_files-1:0),lgres) 3071 lbid = gsn_create_legend(\ 3072 wks,no_files,multi_legend(no_files-1:0),lgres) 2995 3073 2996 3074 amres = True … … 3073 3151 3074 3152 if (prof3d .EQ. 0) then 3075 if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then 3153 if ( isStrSubset( vNam(varn), "time") .OR. \ 3154 isStrSubset( vNam(varn), "NORM")) then 3076 3155 check = False 3077 3156 end if 3078 3157 else 3079 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 3158 if ( isStrSubset( vNam(varn), "time") .OR. \ 3159 isStrSubset( vNam(varn), "zusi") .OR. \ 3160 isStrSubset( vNam(varn), "zwwi") .OR. \ 3161 isStrSubset( vNam(varn), "x") .OR. \ 3162 isStrSubset( vNam(varn), "xu") .OR. \ 3163 isStrSubset( vNam(varn), "y") .OR. \ 3164 isStrSubset( vNam(varn), "yv") .OR. \ 3165 isStrSubset( vNam(varn), "zu_3d") .OR. \ 3166 isStrSubset( vNam(varn), "zw_3d")) then 3080 3167 check = False 3081 3168 end if … … 3162 3249 plot(n) = gsn_csm_xy(wks,data(varn,:,:),z,res) 3163 3250 3164 if (vNam(varn) .EQ. "u" .OR. vNam(varn) .EQ. "v" .OR. vNam(varn) .EQ. "w") then 3251 if (vNam(varn) .EQ. "u" .OR. vNam(varn) .EQ. "v" .OR. \ 3252 vNam(varn) .EQ. "w") then 3165 3253 if (u .EQ. 0) then 3166 3254 res@gsnLeftString = "u, v and w" … … 3186 3274 3187 3275 ; *************************************************** 3188 ; legend for combined plot3276 ; legend for overlaid plot 3189 3277 ; *************************************************** 3190 3278 … … 3193 3281 lgres@lgLabelFont = "helvetica" 3194 3282 lgres@lgLabelFontHeightF = font_size_legend 3195 lgres@vpWidthF = 0.0 63283 lgres@vpWidthF = 0.07 3196 3284 lgres@vpHeightF = 0.12 3197 3285 lgres@lgDashIndexes = (/0,1,2/) … … 3199 3287 3200 3288 amres = True 3201 amres@amParallelPosF = 0. 653202 amres@amOrthogonalPosF = -0.23203 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3289 amres@amParallelPosF = 0.88 3290 amres@amOrthogonalPosF = 0.33 3291 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3204 3292 overlay(plot(n),plot_u) 3205 3293 u=1 … … 3212 3300 end if 3213 3301 3214 if (vNam(varn) .EQ. "pt" .OR. vNam(varn) .EQ. "vpt" .OR. vNam(varn) .EQ. "lpt") then 3302 if (vNam(varn) .EQ. "pt" .OR. vNam(varn) .EQ. "vpt" .OR. \ 3303 vNam(varn) .EQ. "lpt") then 3215 3304 if (pt .EQ. 0) then 3216 3305 res@gsnLeftString = "pt, vpt and lpt" … … 3236 3325 3237 3326 ; *************************************************** 3238 ; legend for combined plot3327 ; legend for overlaid plot 3239 3328 ; *************************************************** 3240 3329 … … 3246 3335 lgres@vpHeightF = 0.12 3247 3336 lgres@lgDashIndexes = (/0,1,2/) 3248 lbid = gsn_create_legend(wks,3,(/"pt","vpt","lpt"/),lgres) 3249 3337 lbid = gsn_create_legend(wks,3,(/"pt","vpt","lpt"/),lgres) 3250 3338 amres = True 3251 amres@amParallelPosF = 0. 653252 amres@amOrthogonalPosF = -0.23253 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3339 amres@amParallelPosF = 0.88 3340 amres@amOrthogonalPosF = 0.33 3341 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3254 3342 overlay(plot(n),plot_pt) 3255 3343 pt=1 … … 3261 3349 end if 3262 3350 end if 3263 if (vNam(varn) .EQ. "q" .OR. vNam(varn) .EQ. "qv" .OR. vNam(varn) .EQ. "ql") then 3351 if (vNam(varn) .EQ. "q" .OR. vNam(varn) .EQ. "qv" .OR. \ 3352 vNam(varn) .EQ. "ql") then 3264 3353 if (q .EQ. 0) then 3265 3354 res@gsnLeftString = "q, qv and ql" … … 3285 3374 3286 3375 ; *************************************************** 3287 ; legend for combined plot3376 ; legend for overlaid plot 3288 3377 ; *************************************************** 3289 3378 … … 3292 3381 lgres@lgLabelFont = "helvetica" 3293 3382 lgres@lgLabelFontHeightF = font_size_legend 3294 lgres@vpWidthF = 0.0 63383 lgres@vpWidthF = 0.07 3295 3384 lgres@vpHeightF = 0.12 3296 3385 lgres@lgDashIndexes = (/0,1,2/) 3297 lbid = gsn_create_legend(wks,3,(/"q","qv","ql"/),lgres) 3386 lbid = gsn_create_legend(wks,3,(/"q","qv","ql"/),lgres) 3298 3387 3299 3388 amres = True 3300 amres@amParallelPosF = 0. 653301 amres@amOrthogonalPosF = -0.23302 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3389 amres@amParallelPosF = 0.88 3390 amres@amOrthogonalPosF = 0.33 3391 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3303 3392 overlay(plot(n),plot_q) 3304 3393 q=1 … … 3311 3400 end if 3312 3401 3313 if (vNam(varn) .EQ. "e" .OR. vNam(varn) .EQ. "es" .OR. vNam(varn) .EQ. "e*" ) then 3402 if (vNam(varn) .EQ. "e" .OR. vNam(varn) .EQ. "es" .OR. \ 3403 vNam(varn) .EQ. "e*" ) then 3314 3404 if (e .EQ. 0) then 3315 3405 res@gsnLeftString = "e and e*" … … 3332 3422 3333 3423 ; *************************************************** 3334 ; legend for combined plot3424 ; legend for overlaid plot 3335 3425 ; *************************************************** 3336 3426 … … 3339 3429 lgres@lgLabelFont = "helvetica" 3340 3430 lgres@lgLabelFontHeightF = font_size_legend 3341 lgres@vpWidthF = 0.0 63431 lgres@vpWidthF = 0.07 3342 3432 lgres@vpHeightF = 0.08 3343 3433 lgres@lgDashIndexes = (/0,1,2/) … … 3345 3435 3346 3436 amres = True 3347 amres@amParallelPosF = 0. 653348 amres@amOrthogonalPosF = -0.23349 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3437 amres@amParallelPosF = 0.88 3438 amres@amOrthogonalPosF = 0.365 3439 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3350 3440 overlay(plot(n),plot_e) 3351 3441 e=1 … … 3378 3468 3379 3469 ; *************************************************** 3380 ; legend for combined plot3470 ; legend for overlaid plot 3381 3471 ; *************************************************** 3382 3472 … … 3385 3475 lgres@lgLabelFont = "helvetica" 3386 3476 lgres@lgLabelFontHeightF = font_size_legend 3387 lgres@vpWidthF = 0.0 63477 lgres@vpWidthF = 0.07 3388 3478 lgres@vpHeightF = 0.08 3389 3479 lgres@lgDashIndexes = (/0,1,2/) … … 3391 3481 3392 3482 amres = True 3393 amres@amParallelPosF = 0. 653394 amres@amOrthogonalPosF = -0.23395 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3483 amres@amParallelPosF = 0.88 3484 amres@amOrthogonalPosF = 0.365 3485 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3396 3486 overlay(plot(n),plot_km) 3397 3487 km=1 … … 3404 3494 end if 3405 3495 3406 if (vNam(varn) .EQ. "wpup" .OR. vNam(varn) .EQ. "wsus" .OR. vNam(varn) .EQ. "wu" \ 3407 .OR. vNam(varn) .EQ. "w"+dq+"u"+dq .OR. vNam(varn) .EQ. "w*u*") then 3496 if (vNam(varn) .EQ. "wpup" .OR. vNam(varn) .EQ. "wsus" .OR. \ 3497 vNam(varn) .EQ. "wu" .OR. vNam(varn) .EQ. "w"+dq+"u"+dq .OR. \ 3498 vNam(varn) .EQ. "w*u*") then 3408 3499 if (wpup .EQ. 0) then 3409 3500 res@gsnLeftString = "w"+dq+"u"+dq+", w*u* and wu" … … 3429 3520 3430 3521 ; *************************************************** 3431 ; legend for combined plot3522 ; legend for overlaid plot 3432 3523 ; *************************************************** 3433 3524 … … 3439 3530 lgres@vpHeightF = 0.12 3440 3531 lgres@lgDashIndexes = (/0,1,2/) 3441 lbid = gsn_create_legend(wks,3,(/"w"+dq+"u"+dq,"w*u*","wu"/),lgres) 3532 lbid = gsn_create_legend(\ 3533 wks,3,(/"w"+dq+"u"+dq,"w*u*","wu"/),lgres) 3442 3534 3443 3535 amres = True 3444 amres@amParallelPosF = 0. 653445 amres@amOrthogonalPosF = -0.23446 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3536 amres@amParallelPosF = 0.88 3537 amres@amOrthogonalPosF = 0.33 3538 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3447 3539 overlay(plot(n),plot_wpup) 3448 3540 wpup=1 … … 3454 3546 end if 3455 3547 end if 3456 if (vNam(varn) .EQ. "wpvp" .OR. vNam(varn) .EQ. "wsvs" .OR.vNam(varn) .EQ. "wv"\ 3457 .OR. vNam(varn) .EQ. "w"+dq+"v"+dq .OR. vNam(varn) .EQ. "w*v*") then 3548 if (vNam(varn) .EQ. "wpvp" .OR. vNam(varn) .EQ. "wsvs" .OR. \ 3549 vNam(varn) .EQ. "wv" .OR. vNam(varn) .EQ. "w"+dq+"v"+dq .OR. \ 3550 vNam(varn) .EQ. "w*v*") then 3458 3551 if (wpvp .EQ. 0) then 3459 3552 res@gsnLeftString = "w"+dq+"v"+dq+", w*v* and wv" … … 3479 3572 3480 3573 ; *************************************************** 3481 ; legend for combined plot3574 ; legend for overlaid plot 3482 3575 ; *************************************************** 3483 3576 … … 3489 3582 lgres@vpHeightF = 0.12 3490 3583 lgres@lgDashIndexes = (/0,1,2/) 3491 lbid = gsn_create_legend(wks,3,(/"w"+dq+"v"+dq,"w*v*","wv"/),lgres) 3584 lbid = gsn_create_legend(\ 3585 wks,3,(/"w"+dq+"v"+dq,"w*v*","wv"/),lgres) 3492 3586 3493 3587 amres = True 3494 amres@amParallelPosF = 0. 653495 amres@amOrthogonalPosF = -0.23496 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3588 amres@amParallelPosF = 0.88 3589 amres@amOrthogonalPosF = 0.33 3590 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3497 3591 overlay(plot(n),plot_wpvp) 3498 3592 wpvp=1 … … 3504 3598 end if 3505 3599 end if 3506 if (vNam(varn) .EQ. "wpptp" .OR. vNam(varn) .EQ. "wspts" .OR. vNam(varn) .EQ. "wpt"\ 3507 .OR. vNam(varn) .EQ. "w"+dq+"pt"+dq .OR. vNam(varn) .EQ. "w*pt*") then 3600 if (vNam(varn) .EQ. "wpptp" .OR. vNam(varn) .EQ. "wspts" .OR. \ 3601 vNam(varn) .EQ. "wpt" .OR. vNam(varn) .EQ. "w"+dq+"pt"+dq .OR.\ 3602 vNam(varn) .EQ. "w*pt*") then 3508 3603 if (wpptp .EQ. 0) then 3509 3604 res@gsnLeftString = "w"+dq+"pt"+dq+", w*pt* and wpt" … … 3529 3624 3530 3625 ; *************************************************** 3531 ; legend for combined plot3626 ; legend for overlaid plot 3532 3627 ; *************************************************** 3533 3628 … … 3539 3634 lgres@vpHeightF = 0.12 3540 3635 lgres@lgDashIndexes = (/0,1,2/) 3541 lbid = gsn_create_legend(wks,3,(/"w"+dq+"pt"+dq,"w*pt*","wpt"/),lgres) 3636 lbid = gsn_create_legend(\ 3637 wks,3,(/"w"+dq+"pt"+dq,"w*pt*","wpt"/),lgres) 3542 3638 3543 3639 amres = True 3544 amres@amParallelPosF = 0. 653545 amres@amOrthogonalPosF = -0.23546 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3640 amres@amParallelPosF = 0.88 3641 amres@amOrthogonalPosF = 0.33 3642 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3547 3643 overlay(plot(n),plot_wpptp) 3548 3644 wpptp=1 … … 3554 3650 end if 3555 3651 end if 3556 if (vNam(varn) .EQ. "wsptsBC" .OR. vNam(varn) .EQ. "wptBC" .OR. vNam(varn) .EQ. "w*pt*BC") then 3652 if (vNam(varn) .EQ. "wsptsBC" .OR. vNam(varn) .EQ. "wptBC" .OR.\ 3653 vNam(varn) .EQ. "w*pt*BC") then 3557 3654 if (wsptsBC .EQ. 0) then 3558 3655 res@gsnLeftString = "w*pt*BC and wptBC" … … 3575 3672 3576 3673 ; *************************************************** 3577 ; legend for combined plot3674 ; legend for overlaid plot 3578 3675 ; *************************************************** 3579 3676 … … 3585 3682 lgres@vpHeightF = 0.12 3586 3683 lgres@lgDashIndexes = (/0,1,2/) 3587 lbid = gsn_create_legend(wks,3,(/"w*pt*BC","wptBC"/),lgres) 3684 lbid = gsn_create_legend(\ 3685 wks,3,(/"w*pt*BC","wptBC"/),lgres) 3588 3686 3589 3687 amres = True 3590 amres@amParallelPosF = 0. 653591 amres@amOrthogonalPosF = -0.23592 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3688 amres@amParallelPosF = 0.88 3689 amres@amOrthogonalPosF = 0.33 3690 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3593 3691 overlay(plot(n),plot_wsptsBC) 3594 3692 wsptsBC=1 … … 3600 3698 end if 3601 3699 end if 3602 if (vNam(varn) .EQ. "wpvptp" .OR. vNam(varn) .EQ. "wsvpts" .OR. vNam(varn) .EQ. "wvpt"\ 3603 .OR. vNam(varn) .EQ. "w"+dq+"vpt"+dq .OR. vNam(varn) .EQ. "w*vpt*") then 3700 if (vNam(varn) .EQ. "wpvptp" .OR. vNam(varn) .EQ. "wsvpts" .OR. \ 3701 vNam(varn) .EQ. "wvpt" .OR. vNam(varn) .EQ. \ 3702 "w"+dq+"vpt"+dq .OR. vNam(varn) .EQ. "w*vpt*") then 3604 3703 if (wpvptp .EQ. 0) then 3605 3704 res@gsnLeftString = "w"+dq+"vpt"+dq+", w*vpt* and wvpt" … … 3625 3724 3626 3725 ; *************************************************** 3627 ; legend for combined plot3726 ; legend for overlaid plot 3628 3727 ; *************************************************** 3629 3728 … … 3635 3734 lgres@vpHeightF = 0.12 3636 3735 lgres@lgDashIndexes = (/0,1,2/) 3637 lbid = gsn_create_legend( wks,3,(/"w"+dq+"vpt"+dq,"w*vpt*","wvpt"/),lgres)3638 3736 lbid = gsn_create_legend(\ 3737 wks,3,(/"w"+dq+"vpt"+dq,"w*vpt*","wvpt"/),lgres) 3639 3738 amres = True 3640 amres@amParallelPosF = 0. 653641 amres@amOrthogonalPosF = -0.23642 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3739 amres@amParallelPosF = 0.88 3740 amres@amOrthogonalPosF = 0.33 3741 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3643 3742 overlay(plot(n),plot_wpvptp) 3644 3743 wpvptp=1 … … 3650 3749 end if 3651 3750 end if 3652 if (vNam(varn) .EQ. "wpqp" .OR. vNam(varn) .EQ. "wsqs" .OR. vNam(varn) .EQ. "wq"\ 3653 .OR. vNam(varn) .EQ. "w"+dq+"q"+dq .OR. vNam(varn) .EQ. "w*q*") then 3751 if (vNam(varn) .EQ. "wpqp" .OR. vNam(varn) .EQ. "wsqs" .OR. \ 3752 vNam(varn) .EQ. "wq" .OR. vNam(varn) .EQ. "w"+dq+"q"+dq .OR. \ 3753 vNam(varn) .EQ. "w*q*") then 3654 3754 if (wpqp .EQ. 0) then 3655 3755 res@gsnLeftString = "w"+dq+"q"+dq+", w*q* and wq" … … 3675 3775 3676 3776 ; *************************************************** 3677 ; legend for combined plot3777 ; legend for overlaid plot 3678 3778 ; *************************************************** 3679 3779 … … 3685 3785 lgres@vpHeightF = 0.12 3686 3786 lgres@lgDashIndexes = (/0,1,2/) 3687 lbid = gsn_create_legend(wks,3,(/"w"+dq+"q"+dq,"w*q*","wq"/),lgres) 3787 lbid = gsn_create_legend(\ 3788 wks,3,(/"w"+dq+"q"+dq,"w*q*","wq"/),lgres) 3688 3789 3689 3790 amres = True 3690 amres@amParallelPosF = 0. 653691 amres@amOrthogonalPosF = -0.23692 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3791 amres@amParallelPosF = 0.88 3792 amres@amOrthogonalPosF = 0.33 3793 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3693 3794 overlay(plot(n),plot_wpqp) 3694 3795 wpqp=1 … … 3700 3801 end if 3701 3802 end if 3702 if (vNam(varn) .EQ. "wpqvp" .OR. vNam(varn) .EQ. "wsqvs" .OR. vNam(varn) .EQ. "wqv"\ 3703 .OR. vNam(varn) .EQ. "w"+dq+"qv"+dq .OR. vNam(varn) .EQ. "w*qv*") then 3803 if (vNam(varn) .EQ. "wpqvp" .OR. vNam(varn) .EQ. "wsqvs" .OR. \ 3804 vNam(varn) .EQ. "wqv" .OR. vNam(varn) .EQ. "w"+dq+"qv"+dq .OR.\ 3805 vNam(varn) .EQ. "w*qv*") then 3704 3806 if (wpqvp .EQ. 0) then 3705 3807 res@gsnLeftString ="w"+dq+"qv"+dq+" , w*qv* and wqv" … … 3725 3827 3726 3828 ; *************************************************** 3727 ; legend for combined plot3829 ; legend for overlaid plot 3728 3830 ; *************************************************** 3729 3831 … … 3735 3837 lgres@vpHeightF = 0.12 3736 3838 lgres@lgDashIndexes = (/0,1,2/) 3737 lbid = gsn_create_legend(wks,3,(/"w"+dq+"qv"+dq,"w*qv*","wqv"/),lgres) 3839 lbid = gsn_create_legend(\ 3840 wks,3,(/"w"+dq+"qv"+dq,"w*qv*","wqv"/),lgres) 3738 3841 3739 3842 amres = True 3740 amres@amParallelPosF = 0. 653741 amres@amOrthogonalPosF = -0.23742 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3843 amres@amParallelPosF = 0.88 3844 amres@amOrthogonalPosF = 0.33 3845 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3743 3846 overlay(plot(n),plot_wpqvp) 3744 3847 wpqvp=1 … … 3750 3853 end if 3751 3854 end if 3752 if (vNam(varn) .EQ. "wpsp" .OR. vNam(varn) .EQ. "wsss" .OR. vNam(varn) .EQ. "ws"\ 3753 .OR. vNam(varn) .EQ. "w"+dq+"s"+dq .OR. vNam(varn) .EQ. "w*s*") then 3855 if (vNam(varn) .EQ. "wpsp" .OR. vNam(varn) .EQ. "wsss" .OR. \ 3856 vNam(varn) .EQ. "ws" .OR. vNam(varn) .EQ. "w"+dq+"s"+dq .OR.\ 3857 vNam(varn) .EQ. "w*s*") then 3754 3858 if (wpsp .EQ. 0) then 3755 3859 res@gsnLeftString = "w"+dq+"s"+dq+", w*s* and ws" … … 3775 3879 3776 3880 ; *************************************************** 3777 ; legend for combined plot3881 ; legend for overlaid plot 3778 3882 ; *************************************************** 3779 3883 … … 3785 3889 lgres@vpHeightF = 0.12 3786 3890 lgres@lgDashIndexes = (/0,1,2/) 3787 lbid = gsn_create_legend(wks,3,(/"w"+dq+"s"+dq,"w*s*","ws"/),lgres) 3891 lbid = gsn_create_legend(\ 3892 wks,3,(/"w"+dq+"s"+dq,"w*s*","ws"/),lgres) 3788 3893 3789 3894 amres = True 3790 amres@amParallelPosF = 0. 653791 amres@amOrthogonalPosF = -0.23792 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3895 amres@amParallelPosF = 0.88 3896 amres@amOrthogonalPosF = 0.33 3897 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3793 3898 overlay(plot(n),plot_wpsp) 3794 3899 wpsp=1 … … 3800 3905 end if 3801 3906 end if 3802 if (vNam(varn) .EQ. "wpsap" .OR.vNam(varn) .EQ. "wssas" .OR. vNam(varn) .EQ. "wsa"\ 3803 .OR. vNam(varn) .EQ. "w"+dq+"sa"+dq .OR. vNam(varn) .EQ. "w*sa*") then 3907 if (vNam(varn) .EQ. "wpsap" .OR.vNam(varn) .EQ. "wssas" .OR. \ 3908 vNam(varn) .EQ. "wsa" .OR. vNam(varn) .EQ. "w"+dq+"sa"+dq .OR.\ 3909 vNam(varn) .EQ. "w*sa*") then 3804 3910 if (wpsap .EQ. 0) then 3805 3911 res@gsnLeftString = "w"+dq+"sa"+dq+", w*sa* and wsa" … … 3825 3931 3826 3932 ; *************************************************** 3827 ; legend for combined plot3933 ; legend for overlaid plot 3828 3934 ; *************************************************** 3829 3935 … … 3835 3941 lgres@vpHeightF = 0.12 3836 3942 lgres@lgDashIndexes = (/0,1,2/) 3837 lbid = gsn_create_legend( wks,3,(/"w"+dq+"sa"+dq,"w*sa*","wsa"/),lgres)3838 3943 lbid = gsn_create_legend(\ 3944 wks,3,(/"w"+dq+"sa"+dq,"w*sa*","wsa"/),lgres) 3839 3945 amres = True 3840 amres@amParallelPosF = 0. 653841 amres@amOrthogonalPosF = -0.23842 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3946 amres@amParallelPosF = 0.88 3947 amres@amOrthogonalPosF = 0.33 3948 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3843 3949 overlay(plot(n),plot_wpsap) 3844 3950 wpsap=1 … … 3851 3957 end if 3852 3958 3853 if (vNam(varn) .EQ. "us2" .OR. vNam(varn) .EQ. "vs2" .OR. vNam(varn) .EQ. "ws2" \ 3854 .OR. vNam(varn) .EQ. "u*2" .OR. vNam(varn) .EQ. "v*2" .OR. vNam(varn) .EQ. "w*2" ) then 3959 if (vNam(varn) .EQ. "us2" .OR. vNam(varn) .EQ. "vs2" .OR. \ 3960 vNam(varn) .EQ. "ws2" .OR. vNam(varn) .EQ. "u*2" .OR. \ 3961 vNam(varn) .EQ. "v*2" .OR. vNam(varn) .EQ. "w*2" ) then 3855 3962 if (us2 .EQ. 0) then 3856 3963 res@gsnLeftString = "u*2, v*2 and w*2" … … 3876 3983 3877 3984 ; *************************************************** 3878 ; legend for combined plot3985 ; legend for overlaid plot 3879 3986 ; *************************************************** 3880 3987 … … 3886 3993 lgres@vpHeightF = 0.12 3887 3994 lgres@lgDashIndexes = (/0,1,2/) 3888 lbid = gsn_create_legend(wks,3,(/"u*2","v*2","w*2"/),lgres) 3889 3995 lbid = gsn_create_legend(wks,3,(/"u*2","v*2","w*2"/),lgres) 3890 3996 amres = True 3891 amres@amParallelPosF = 0. 653892 amres@amOrthogonalPosF = -0.23893 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3997 amres@amParallelPosF = 0.88 3998 amres@amOrthogonalPosF = 0.33 3999 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3894 4000 overlay(plot(n),plot_us2) 3895 4001 us2=1 … … 3902 4008 end if 3903 4009 3904 if (vNam(varn) .EQ. "wsususodz" .OR. vNam(varn) .EQ. "wspsodz" .OR. vNam(varn) .EQ. "wpeodz" \ 3905 .OR. vNam(varn) .EQ. "w*u*u*:dz" .OR. vNam(varn) .EQ. "w*p*:dz" .OR. vNam(varn) .EQ. "w"+dq+"e:dz") then 4010 if (vNam(varn) .EQ. "wsususodz" .OR. \ 4011 vNam(varn) .EQ. "wspsodz" .OR. \ 4012 vNam(varn) .EQ. "wpeodz" .OR. \ 4013 vNam(varn) .EQ. "w*u*u*:dz" .OR. \ 4014 vNam(varn) .EQ. "w*p*:dz" .OR. \ 4015 vNam(varn) .EQ. "w"+dq+"e:dz") then 3906 4016 if (wsususodz .EQ. 0) then 3907 4017 res@gsnLeftString = "w*u*u*:dz, w*p*:dz and w"+dq+"e:dz" … … 3909 4019 res@gsnRightString = " " 3910 4020 if (xs .EQ. -1) then 3911 res@trXMinF = min((/miniwsususodz,miniwspsodz,miniwpeodz/)) 4021 res@trXMinF = min((/miniwsususodz,\ 4022 miniwspsodz,miniwpeodz/)) 3912 4023 else 3913 4024 res@trXMinF = xs 3914 4025 end if 3915 4026 if (xe .EQ. -1) then 3916 res@trXMaxF = max((/maxiwsususodz,maxiwspsodz,maxiwpeodz/)) 4027 res@trXMaxF = max((/maxiwsususodz,maxiwspsodz,\ 4028 maxiwpeodz/)) 3917 4029 else 3918 4030 res@trXMaxF = xe … … 3927 4039 3928 4040 ; *************************************************** 3929 ; legend for combined plot4041 ; legend for overlaid plot 3930 4042 ; *************************************************** 3931 4043 … … 3937 4049 lgres@vpHeightF = 0.12 3938 4050 lgres@lgDashIndexes = (/0,1,2/) 3939 lbid = gsn_create_legend( wks,3,(/"w*u*u*:dz","w*p*:dz","w"+dq+"e:dz"/),lgres)3940 4051 lbid = gsn_create_legend(\ 4052 wks,3,(/"w*u*u*:dz","w*p*:dz","w"+dq+"e:dz"/),lgres) 3941 4053 amres = True 3942 amres@amParallelPosF = 0. 653943 amres@amOrthogonalPosF = -0.23944 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 4054 amres@amParallelPosF = 0.88 4055 amres@amOrthogonalPosF = 0.33 4056 annoid1 = gsn_add_annotation(plot(n),lbid,amres) 3945 4057 overlay(plot(n),plot_wsususodz) 3946 4058 wsususodz=1 … … 3970 4082 3971 4083 if (prof3d .EQ. 0) then 3972 if ( isStrSubset( vNam(varn), "time") .OR. isStrSubset( vNam(varn), "NORM")) then 4084 if ( isStrSubset( vNam(varn), "time") .OR. \ 4085 isStrSubset( vNam(varn), "NORM")) then 3973 4086 check = False 3974 4087 end if 3975 4088 else 3976 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 4089 if ( isStrSubset( vNam(varn), "time") .OR. \ 4090 isStrSubset( vNam(varn), "zusi") .OR. \ 4091 isStrSubset( vNam(varn), "zwwi") .OR. \ 4092 isStrSubset( vNam(varn), "x") .OR. \ 4093 isStrSubset( vNam(varn), "xu") .OR. \ 4094 isStrSubset( vNam(varn), "y") .OR. \ 4095 isStrSubset( vNam(varn), "yv") .OR. \ 4096 isStrSubset( vNam(varn), "zu_3d") .OR. \ 4097 isStrSubset( vNam(varn), "zw_3d")) then 3977 4098 check = False 3978 4099 end if … … 4059 4180 print(" ") 4060 4181 print("combining is not possible,") 4061 print("'c_var'(= "+c_var+") must include two variables of the general plots = ") 4182 print("'c_var'(= "+c_var+") must include two variables of "+\ 4183 "the general plots = ") 4062 4184 print("- "+com_var_avail) 4063 4185 print("be sure to have one comma before and after the variable") … … 4073 4195 print(" ") 4074 4196 print("combining is not possible,") 4075 print("'c_var'(= "+c_var+") must include three variables of the general plots = ") 4197 print("'c_var'(= "+c_var+") must include three variables of "+\ 4198 "the general plots = ") 4076 4199 print("- "+com_var_avail) 4077 4200 print("be sure to have one comma before and after the variable") … … 4114 4237 no_frames = 0 4115 4238 4116 if ((format_out .EQ. "eps" .OR. format_out .EQ. "epsi") .AND. n .gt. no_rows*no_columns) then 4239 if ((format_out .EQ. "eps" .OR. format_out .EQ. "epsi") .AND. \ 4240 n .gt. no_rows*no_columns) then 4117 4241 gsn_panel(wks,plot_,(/n,1/),resP) 4118 4242 print(" ") … … 4125 4249 no_frames = no_frames + 1 4126 4250 else 4127 gsn_panel(wks,plot_(i:i+no_rows*no_columns-1),(/no_rows,no_columns/),resP) 4251 gsn_panel(wks,plot_(i:i+no_rows*no_columns-1),\ 4252 (/no_rows,no_columns/),resP) 4128 4253 no_frames = no_frames + 1 4129 4254 end if
Note: See TracChangeset
for help on using the changeset viewer.