Problem outerjoin two tables 20x1 ; 20x8
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Bastiaan Pierik
am 25 Jan. 2021
Beantwortet: Stephen23
am 25 Jan. 2021
%a string of delimiters TC1 and so on
str='TC1;TC2;TC3;TC4;C1;C2;C3;C4'
%create random variables resembling temperature range -10 till 80 20 variables over each 4 rows str2= randi([-10,80],20,4)
%filtering the string on semicolon and place them in rows
output_str=strread(str,'%s','delimiter',';')
str2= randi([-10,80],20,8);
tl=linspace(1,1,20)';
%attaching both strings and create a table.
ArrayZ=array2table(str2,'VariableNames',output_str)
%add array Time ArrayTime=array2table(tl,'VariableNames',"time")
%why can’t I write the two arrays together I have defined both arrays I would like to attach the array on the left side.
Tabletotal=outerjoin(ArrayTime,'MergeKeys',ArrayZ)
0 Kommentare
Akzeptierte Antwort
Stephen23
am 25 Jan. 2021
I don't see why outerjoin is required:
newTable = [ArrayTime,ArrayZ]
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Data Type Conversion finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!