How can I align deterministic signals?
Afficher commentaires plus anciens
I have some results from a shaking table test that have been carried out.
The input was always the same, however, records where started "by-hand" so they always have different starting times leading to signals that are not aligned. Since I am not an expert in signal processing, I need some help to align them.
I add some example data to this topic to give an idea about the data.
Réponse acceptée
Plus de réponses (1)
Some of what SS shows might be easier with timetables:
for i = 1:4
signal = load("ew_data"+i+".mat"); signal = signal.ans;
start = find(abs(signal)>0.05,1,'first');
stop = find(abs(signal)>0.05,1,'last');
tt{i} = timetable(signal(start:stop),RowTimes=seconds(1:(stop-start+1))); % dunno what your time units are
end
ttAll = synchronize(tt{:},"union");
ttAll.Properties.VariableNames = "Signal" + (1:4);
stackedplot(ttAll)
6 commentaires
Image Analyst
le 16 Nov 2023
+1 vote for letting us know about synchronize
Peter Perkins
le 17 Nov 2023
Huh. I think of synchronize as "the value proposition" for timetables. Are you saying you did not know about it? If true, that suggests a documentation shortcoming that we will have to identify.
Star Strider
le 17 Nov 2023
I’ve used synchronize and like it. The problem here is that the time vectors weren’t provided (I had to synthesise them in my response), so without even a sampling frequency (that I arbitrarily assumed was the same for all signals), it didn’t seem applicable.
Peter Perkins
le 17 Nov 2023
Right. I made a lot of assumptions about the time vectors.
alegio20
le 17 Nov 2023
alegio20
le 17 Nov 2023
Catégories
En savoir plus sur Time Series Collections dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!



