restructure and organize

This commit is contained in:
Silas Oettinghaus
2026-06-22 22:58:58 +02:00
parent c4f75b7ec4
commit 33ec5b3116
36 changed files with 1914 additions and 674 deletions

View File

@@ -815,11 +815,18 @@ classdef Signal
pkpos = sort(pkpos);
% if mean(w) > 15 || mean(p) > 15
% return
% else
% sequenceFound = 1;
% end
if isempty(pks)
warning(['Error in findpeaks, ususally the seuqnece is too short. No Peaks detected']);
return
end
if max(p) < 0.3 || median(w) > 15
%median(w) > 15 part means reject if the detected correlation peaks are too broad. That can be sensible: a true sync peak should often be sharp.
warning(['Error in findpeaks, ususally the seuqnece is too short. max(p) = ',num2str(max(p)),'; median(w)=',num2str(median(w)),'']);
return
end
sequenceFound = 1;
if options.debug_plots
figure(121212);clf