From 5aa9d5e00d28c91190a2c07866bb0139275133e3 Mon Sep 17 00:00:00 2001 From: Blaise Thompson Date: Mon, 26 Mar 2018 22:34:02 -0500 Subject: 2018-03-26 22:34 --- processing/join.py | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 processing/join.py (limited to 'processing/join.py') diff --git a/processing/join.py b/processing/join.py new file mode 100644 index 0000000..f3a4203 --- /dev/null +++ b/processing/join.py @@ -0,0 +1,49 @@ +"""Join figure.""" + + +# --- import -------------------------------------------------------------------------------------- + + +import os + +import matplotlib.pyplot as plt + +import WrightTools as wt + + +# --- define -------------------------------------------------------------------------------------- + + +here = os.path.abspath(os.path.dirname(__file__)) + + +# --- workspace ----------------------------------------------------------------------------------- + + +wt.artists.apply_rcparams('publication') + +fig, gs = wt.artists.create_figure(width='double', cols=[1, 0, 1, 1, 1, 'cbar'], nrows=4) + +root = wt.open(os.path.join(here, 'MX2_TSF.wt5')) + +def plot(ax, d): + d.transform('w1', 'w2') + d.sig.clip(0, 4) + ax.pcolor(d) + +# II +ax = plt.subplot(gs[0, 0]) +plot(ax, root.processed_tsf.divided_tsf.II) + +# IS +ax = plt.subplot(gs[1, 0]) +plot(ax, root.processed_tsf.divided_tsf.IS) + +# SS +ax = plt.subplot(gs[2, 0]) +plot(ax, root.processed_tsf.divided_tsf.SS) + + +# savefig +p = os.path.join(here, 'join.png') +plt.show() -- cgit v1.2.3