Fixed optional comparison
This commit is contained in:
parent
fdfbd081d9
commit
bf4e9e6958
1 changed files with 16 additions and 14 deletions
|
@ -111,15 +111,16 @@ ax_fft.plot(
|
|||
alpha=0.2,
|
||||
label="PSD ($\\eta$, cas 1)",
|
||||
)
|
||||
ax_fft.plot(
|
||||
*sgl.welch(eta_, 1 / dt, nperseg=nperseg),
|
||||
lw=1,
|
||||
c="k",
|
||||
alpha=0.2,
|
||||
label="PSD ($\\eta$, cas 2)",
|
||||
)
|
||||
ax_r.plot(phi_eta[0], R, marker="+", label="R (cas 1)")
|
||||
ax_r.plot(phi_eta[0], R_, marker="+", label="R (cas 2)")
|
||||
if config.has_option("post", "compare"):
|
||||
ax_fft.plot(
|
||||
*sgl.welch(eta_, 1 / dt, nperseg=nperseg),
|
||||
lw=1,
|
||||
c="k",
|
||||
alpha=0.2,
|
||||
label="PSD ($\\eta$, cas 2)",
|
||||
)
|
||||
ax_r.plot(phi_eta[0], R_, marker="+", label="R (cas 2)")
|
||||
ax_r.set(xlim=(0, 0.3), ylim=(0, 1), xlabel="f (Hz)", ylabel="R")
|
||||
ax_fft.set(ylim=0, ylabel="PSD (m²/Hz)")
|
||||
ax_r.grid()
|
||||
|
@ -129,16 +130,17 @@ fig_r.tight_layout()
|
|||
|
||||
fig_x, ax_x = plt.subplots(figsize=(10, 1))
|
||||
ax_x.plot(data["x"], -data["botl"], color="k")
|
||||
ax_x.plot(data["x"], -data_comp["botl"], color="k", ls="-.")
|
||||
ax_x.plot(
|
||||
data["x"],
|
||||
np.maximum(data["watl"][arg_t0, :], -data["botl"]),
|
||||
)
|
||||
ax_x.plot(
|
||||
data["x"],
|
||||
np.maximum(data_comp["watl"][arg_t0, :], -data_comp["botl"]),
|
||||
ls="-.",
|
||||
)
|
||||
if config.has_option("post", "compare"):
|
||||
ax_x.plot(data["x"], -data_comp["botl"], color="k", ls="-.")
|
||||
ax_x.plot(
|
||||
data["x"],
|
||||
np.maximum(data_comp["watl"][arg_t0, :], -data_comp["botl"]),
|
||||
ls="-.",
|
||||
)
|
||||
ax_x.axvline(x0, c="k", alpha=0.2)
|
||||
ax_x.set(xlabel="x (m)", ylabel="z (m)")
|
||||
ax_x.autoscale(axis="x", tight=True)
|
||||
|
|
Loading…
Reference in a new issue