From 29bc9c7abba23bc8846b084d7dd794a6a4ef777b Mon Sep 17 00:00:00 2001
From: Gregory Ashton <gregory.ashton@ligo.org>
Date: Mon, 10 Apr 2017 16:47:59 +0200
Subject: [PATCH] Remove detStat plot by default

---
 pyfstat/mcmc_based_searches.py | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/pyfstat/mcmc_based_searches.py b/pyfstat/mcmc_based_searches.py
index b5d0128..d5c9bc7 100644
--- a/pyfstat/mcmc_based_searches.py
+++ b/pyfstat/mcmc_based_searches.py
@@ -735,7 +735,7 @@ class MCMCSearch(core.BaseSearchClass):
 
     def plot_walkers(self, sampler, symbols=None, alpha=0.4, color="k", temp=0,
                      lw=0.1, nprod=0, add_det_stat_burnin=False,
-                     fig=None, axes=None, xoffset=0, plot_det_stat=True,
+                     fig=None, axes=None, xoffset=0, plot_det_stat=False,
                      context='classic', subtractions=None, labelpad=0.05):
         """ Plot all the chains from a sampler """
 
@@ -761,12 +761,16 @@ class MCMCSearch(core.BaseSearchClass):
             if len(subtractions) != self.ndim:
                 raise ValueError('subtractions must be of length ndim')
 
+        if plot_det_stat:
+            extra_subplots = 1
+        else:
+            extra_subplots = 0
         with plt.style.context((context)):
             plt.rcParams['text.usetex'] = True
             if fig is None and axes is None:
                 fig = plt.figure(figsize=(4, 3.0*ndim))
-                ax = fig.add_subplot(ndim+1, 1, 1)
-                axes = [ax] + [fig.add_subplot(ndim+1, 1, i)
+                ax = fig.add_subplot(ndim+extra_subplots, 1, 1)
+                axes = [ax] + [fig.add_subplot(ndim+extra_subplots, 1, i)
                                for i in range(2, ndim+1)]
 
             idxs = np.arange(chain.shape[1])
-- 
GitLab