Skip to content

Commit

Permalink
bug fixes merged from Keith O. sandbox
Browse files Browse the repository at this point in the history
  • Loading branch information
bertinia committed May 1, 2017
1 parent 95e484e commit 238ee58
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 11 deletions.
3 changes: 2 additions & 1 deletion lnd_diag/model1-model2/set_1.ncl
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,8 @@ trendsFlag = stringtointeger(getenv("trends_match_Flag"))

filevar = vars(i)

if (isfilevar(in,filevar))then
info = var_init(vars(i))
if (isfilevar(in,filevar) .and. info@derivedVariable .eq. False)then
if (c13Flag(i) .eq. "C13_") then
x = derive_del13C(vars(i),in,scale_type(i),yrs(m),1)
else
Expand Down
7 changes: 4 additions & 3 deletions lnd_diag/model1-model2/set_2.ncl
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,8 @@ begin
; not found in the file, then filevar will be ""

plot_check = True
if (filevar .ne. "")then
if (filevar .ne. "" .and. info@derivedVariable .eq. False)then

if (isvar("x1")) then
delete(x1)
end if
Expand Down Expand Up @@ -276,7 +277,7 @@ begin
; not found in the file, then filevar will be ""

plot_check = True
if (filevar .ne. "")then
if (filevar .ne. "" .and. info@derivedVariable .eq. False)then
if (isvar("x2")) then
delete(x2)
end if
Expand Down Expand Up @@ -805,7 +806,7 @@ begin
; Note: Don't delete res here - save until after obs are posted.
res@tiMainString = cases(1) ; set case 2 titles
res@gsnCenterString = " (yrs " + yrs_ave2 + ")"
if (vars(i) .eq. "CH4PROD" .or. vars(i) .eq. "CH4_SURF_EBUL_SAT" .or. vars(i) .eq. "CH4_SURF_EBUL_UNSAT" .or. vars(i) .eq. "CPOOL") then
if (vars(i) .eq. "CH4PROD" .or. vars(i) .eq. "CH4_SURF_EBUL_SAT" .or. vars(i) .eq. "CH4_SURF_EBUL_UNSAT" .or. vars(i) .eq. "CPOOL" .or. vars(i) .eq. "FERT" .or. vars(i) .eq. "FERT_TO_SMINN") then
if (isatt(res,"cnLabelBarEndStyle")) then
if (res@cnLabelBarEndStyle.eq."IncludeMinMaxLabels") then
res@cnLabelBarEndStyle = "IncludeOuterBoxes" ; temporarily turn off minmax labels.
Expand Down
12 changes: 7 additions & 5 deletions lnd_diag/model1-model2/set_6.ncl
Original file line number Diff line number Diff line change
Expand Up @@ -116,14 +116,15 @@ nplots = 12
if (p .eq. 1) then
fileName = "set6_radFlx.txt"
plot_name = "radf"
titstr = new(7,"string")
titstr = new(8,"string")
titstr(0) = "Incoming Solar"
titstr(1) = "Albedo"
titstr(2) = "Absorbed Solar"
titstr(3) = "Incoming Longwave"
titstr(4) = "Emitted Longwave"
titstr(5) = "Net Longwave"
titstr(6) = "Net Radiation"
titstr(7) = "Ground Snow Covered Fraction"
end if
if (p .eq. 2) then
fileName = "set6_turbFlx.txt"
Expand All @@ -136,7 +137,7 @@ nplots = 12
titstr(4) = "Canopy Evaporation"
titstr(5) = "Ground Evaporation"
titstr(6) = "Ground Heat + Snow Melt"
titstr(7) = "Soil moisture factor (BTRAN)"
titstr(7) = "Soil moisture factor (BTRAN or BTRANMN)"
titstr(8) = "Total LAI"
end if
if (p .eq. 3) then
Expand All @@ -162,7 +163,7 @@ nplots = 12
titstr(4) = "Heterotrophic Respiration"
titstr(5) = "Ecosystem Respiration"
titstr(6) = "Gridcell Surface CH4 Flux"
titstr(7) = "Leached Mineral Nitrogen"
titstr(7) = "Carbon Use Efficiency (NPP/GPP)"
titstr(8) = "Soil NO3 Pool Loss to Leaching"
titstr(9) = "Soil NO3 Pool Loss to Runoff"
else
Expand Down Expand Up @@ -464,7 +465,8 @@ nplots = 12
; check for variables in case 1
info = var_init(vars(i))
vcheck1(i) = True
if(isfilevar(in1,vars(i)))then
if(isfilevar(in1,vars(i)) .and. info@derivedVariable .eq. False)then

x1 = in1->$vars(i)$
plot_check = True
rank = dimsizes(dimsizes(x1))
Expand All @@ -479,7 +481,7 @@ nplots = 12
end if
; check for variables in case 2
vcheck2(i) = True
if(isfilevar(in2,vars(i)))then
if(isfilevar(in2,vars(i)) .and. info@derivedVariable .eq. False)then
x2 = in2->$vars(i)$
else
if (info@derivedVariable .eq. True) then
Expand Down
4 changes: 2 additions & 2 deletions lnd_diag/shared/lnd_create_webpage.pl
Original file line number Diff line number Diff line change
Expand Up @@ -373,11 +373,11 @@ sub setDescription
}
if ($set == 10)
{
$l = "Horizontal contour plots of DJF, MAM, JJA, SON, and ANN means, zoomed in on the Greenland ice sheet (courtesy: Jan Lenaerts, jtmlenaerts@gmail.com) </b><br>";
$l = "Horizontal contour plots of DJF, MAM, JJA, SON, and ANN means, zoomed in on the Greenland ice sheet </b><br>";
}
if ($set == 11)
{
$l = "Horizontal contour plots of DJF, MAM, JJA, SON, and ANN means, zoomed in on the Antarctic ice sheet (courtesy: Jan Lenaerts, jtmlenaerts@gmail.com) </b><br>";
$l = "Horizontal contour plots of DJF, MAM, JJA, SON, and ANN means, zoomed in on the Antarctic ice sheet </b><br>";
}
if ($set == 12)
{
Expand Down

0 comments on commit 238ee58

Please sign in to comment.