Skip to content

Commit

Permalink
Degrees now in vcs plots.
Browse files Browse the repository at this point in the history
  • Loading branch information
zshaheen committed Jun 26, 2018
1 parent d59ef7b commit a1cefdf
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
3 changes: 3 additions & 0 deletions acme_diags/plot/vcs/lat_lon_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,13 @@ def plot(reference, test, diff, metrics_dict, parameter):

reference_isofill = vcs.getisofill('reference_isofill')
reference_isofill.missing = 'grey'
reference_isofill.yticlabels1 = {-90:"90$^\circ$S", -60:"60$^\circ$S", -30:"30$^\circ$S", 0:"0$^\circ$", 30:"30$^\circ$N", 60:"60$^\circ$N", 90:"90$^\circ$N"}
test_isofill = vcs.getisofill('test_isofill')
test_isofill.missing = 'grey'
test_isofill.yticlabels1 = {-90:"90$^\circ$S", -60:"60$^\circ$S", -30:"30$^\circ$S", 0:"0$^\circ$", 30:"30$^\circ$N", 60:"60$^\circ$N", 90:"90$^\circ$N"}
diff_isofill = vcs.getisofill('diff_isofill')
diff_isofill.missing = 'grey'
diff_isofill.yticlabels1 = {-90:"90$^\circ$S", -60:"60$^\circ$S", -30:"30$^\circ$S", 0:"0$^\circ$", 30:"30$^\circ$N", 60:"60$^\circ$N", 90:"90$^\circ$N"}

utils.set_levels_of_graphics_method(
reference_isofill, parameter.contour_levels, reference, test)
Expand Down
18 changes: 18 additions & 0 deletions acme_diags/plot/vcs/polar_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,28 @@ def plot(reference, test, diff, metrics_dict, parameter):

reference_isofill = vcs.getisofill('reference_isofill')
reference_isofill.missing = 'grey'
reference_isofill.xticlabels1 = {
0: "0", 30: "30$^\circ$E", 60: "60$^\circ$E", 90: "90$^\circ$E", 120: "120$^\circ$E",
150: "150$^\circ$E", 180: "180$^\circ$W", 210: "150$^\circ$W", 240: "120$^\circ$W",
270: "90$^\circ$W", 300: "60$^\circ$W", 330: "30$^\circ$W"
}

test_isofill = vcs.getisofill('test_isofill')
test_isofill.missing = 'grey'
test_isofill.xticlabels1 = {
0: "0", 30: "30$^\circ$E", 60: "60$^\circ$E", 90: "90$^\circ$E", 120: "120$^\circ$E",
150: "150$^\circ$E", 180: "180$^\circ$W", 210: "150$^\circ$W", 240: "120$^\circ$W",
270: "90$^\circ$W", 300: "60$^\circ$W", 330: "30$^\circ$W"
}

diff_isofill = vcs.getisofill('diff_isofill')
diff_isofill.missing = 'grey'
diff_isofill.xticlabels1 = {
0: "0", 30: "30$^\circ$E", 60: "60$^\circ$E", 90: "90$^\circ$E", 120: "120$^\circ$E",
150: "150$^\circ$E", 180: "180$^\circ$W", 210: "150$^\circ$W", 240: "120$^\circ$W",
270: "90$^\circ$W", 300: "60$^\circ$W", 330: "30$^\circ$W"
}

if parameter.var_region.lower().find('polar') != -1:
reference_isofill.projection = 'polar'
test_isofill.projection = 'polar'
Expand Down

0 comments on commit a1cefdf

Please sign in to comment.