Lookup values in a table and copy a corresponding value in another table
17 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Gabi
am 18 Aug. 2022
Beantwortet: Atsushi Ueno
am 18 Aug. 2022
Hi,
I have 2 tables, 1 containg the data 'E' (data.mat in this case 2 columns lap and time) and 1 containing the laps for which I'm interested to get the time values from the 1'st table called 'Find'. In essence, I'm looking for something similar to a look up function for this which will write the the coresponding values in a new column in the 'Find' table.
Thanks.
0 Kommentare
Akzeptierte Antwort
Atsushi Ueno
am 18 Aug. 2022
load data
load find
E
Find
[tf, rows] = ismember(Find,E(:,1))
table(rows, E.Time(rows),'VariableNames',{'FoundLap','Time'})
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Database Toolbox 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!