Skip to content

Commit

Permalink
Enjance title for plot_baseline_displacement*() functions
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexey Pechnikov committed May 20, 2024
1 parent e52d315 commit 60557f0
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions pygmtsar/pygmtsar/Stack_sbas.py
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ def plot_baseline_deviation(self, baseline_pairs, pairs_best=None, column='stdde
#print ('NOTE: this function is deprecated, use instead Stack.plot_baseline_attribute()')
self.plot_baseline_attribute(baseline_pairs, pairs_best, column=column, caption='Baseline Deviation')

def plot_baseline_displacement(self, phase, corr=None, caption=None, cmap='turbo',
def plot_baseline_displacement(self, phase, corr=None, caption='LSQ and STL Displacement Models, [rad]', cmap='turbo',
displacement=True, unwrap=True,
stl=False, stl_freq='W', stl_periods=52, stl_robust=True,
los=False, tolerance=np.pi/2, xlabel_rotation=45,
Expand Down Expand Up @@ -900,15 +900,13 @@ def plot_baseline_displacement(self, phase, corr=None, caption=None, cmap='turbo
plt.xticks(rotation=xlabel_rotation)
plt.xlabel('Timeline')
plt.ylabel(f'{name}, [{unit}]')
plt.title('Displacement' \
+ (f' RMSE={rmse:0.3f} [{unit}]' if displacement or stl else '') \
+ (f'\n{caption}' if caption is not None else ''))
plt.title(f'{caption}\n' + (f'RMSE={rmse:0.3f} [{unit}]' if displacement or stl else ''))
plt.xlim([dates[0], dates[-1]])
if (displacement or stl) and legend:
plt.legend(framealpha=legend_alpha)

def plot_baseline_displacement_los_mm(self, phase, corr=None, caption=None, cmap='turbo',
displacement=True, unwrap=True,
def plot_baseline_displacement_los_mm(self, phase, corr=None, caption='LSQ and STL Displacement Models, [mm]',
cmap='turbo', displacement=True, unwrap=True,
stl=False, stl_freq='W', stl_periods=52, stl_robust=True,
tolerance=np.pi/2, xlabel_rotation=45,
legend=True, legend_alpha=None, linewidth=0.5):
Expand Down

0 comments on commit 60557f0

Please sign in to comment.