aboutsummaryrefslogtreecommitdiff
path: root/processing/join.py
diff options
context:
space:
mode:
authorBlaise Thompson <blaise@untzag.com>2018-03-26 22:34:02 -0500
committerBlaise Thompson <blaise@untzag.com>2018-03-26 22:34:02 -0500
commit5aa9d5e00d28c91190a2c07866bb0139275133e3 (patch)
treeefee9a2879b774cdcad22cffd9e6218f852e0604 /processing/join.py
parent8c899a01c80fdceab395e5c11389ca8334c67864 (diff)
2018-03-26 22:34
Diffstat (limited to 'processing/join.py')
-rw-r--r--processing/join.py49
1 files changed, 49 insertions, 0 deletions
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()