How can I distinguish between events in data?
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Charles Brown-King
am 4 Feb. 2016
Bearbeitet: Ingrid
am 4 Feb. 2016
I've been given data with 87 events that consist of 130 numbers each. The boundary of each event is is shown by the number 1. How can I get Matlab to distinguish between these events? If I want to plot them all on the same graph together, for example.
In other words I have a text file with 11397 numbers in it (131*87) and every 131st number is the number 1 and is not actual data.
(Example of the boundary between events) 2052 2054 2052 2052 2048 1 2053 2053 2051 2054 2052
0 Kommentare
Akzeptierte Antwort
Ingrid
am 4 Feb. 2016
Bearbeitet: Ingrid
am 4 Feb. 2016
since all your events have the same number of value, you do not really need the delimiter value to indicate that a new event starts and you could just read in the data and then use reshape so that you have 131 rows, discard the last row (which are all ones) and then transpose if required
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Workspace Variables and MAT-Files finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!