From 8cf81bcb4418e4ee1cd87b8d5993edf1e28bdeda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Boisselier?= Date: Sun, 30 Jun 2024 22:41:06 +0200 Subject: [PATCH] better sync of the peaks pair for close frequencies --- shaketune/graph_creators/belts_graph_creator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shaketune/graph_creators/belts_graph_creator.py b/shaketune/graph_creators/belts_graph_creator.py index fd94d76..39a837c 100644 --- a/shaketune/graph_creators/belts_graph_creator.py +++ b/shaketune/graph_creators/belts_graph_creator.py @@ -374,7 +374,7 @@ def plot_versus_belts( freq1 = signal1.freqs[peak1[0]] freq2 = signal2.freqs[peak2[0]] - if freq1 == freq2: + if abs(freq1 - freq2) < 1: ax.plot(signal1.psd[peak1[0]], signal2.psd[peak2[0]], marker='o', color='black', markersize=7) ax.annotate( f'{label}1/{label}2',