Skip to content

Commit 350c16b

Browse files
committed
Update inversion_1d.py
1 parent a9315e6 commit 350c16b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

mtpy/modeling/simpeg/recipes/inversion_1d.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ def _plot_z(self):
417417
z_grid = np.r_[0.0, np.cumsum(self.thicknesses[::-1])]
418418
return z_grid / 1000
419419

420-
def plot_response(self, iteration=None, fig_num=2):
420+
def plot_response(self, iteration=None, fig_num=1, **kwargs):
421421
"""Plot response.
422422
:param fig_num:
423423
Defaults to 2.
@@ -458,7 +458,8 @@ def plot_response(self, iteration=None, fig_num=2):
458458
ax_model.set_ylim((self._plot_z.max(), 0.01))
459459
ax_model.set_ylabel("Depth (km)")
460460
ax_model.set_xscale("log")
461-
ax_model.set_yscale("symlog")
461+
yscale = kwargs.get("yscale", "symlog")
462+
ax_model.set_yscale(yscale)
462463
ax_model.yaxis.set_major_locator(LogLocator(base=10.0, numticks=10))
463464
ax_model.yaxis.set_minor_locator(
464465
LogLocator(base=10.0, numticks=10, subs="auto")
@@ -467,6 +468,7 @@ def plot_response(self, iteration=None, fig_num=2):
467468
ax_model.xaxis.set_minor_locator(
468469
LogLocator(base=10.0, numticks=10, subs="auto")
469470
)
471+
470472
ax_model.grid(which="both", alpha=0.5)
471473

472474
nf = len(self.frequencies)

0 commit comments

Comments
 (0)