Filter löschen
Filter löschen

How to assign a title to each row of a table?

2 Ansichten (letzte 30 Tage)
Kyana Shayan
Kyana Shayan am 17 Mär. 2017
Beantwortet: Sean de Wolski am 17 Mär. 2017
Hello Everyone,
I am trying to a make a 4*6 table which I only have the values for first row for now. When I try to assign names to the rows, I keep having this message. I can't find the problem, since I made a 2*8 table just in the same way before.
Thank you for helping me. Here is the code:
LastName = {'Analyical PSDs'; 'Experimental Non-smoothed Periodograms'; 'Experimental Smoothed Peridograms'; 'Time Traces'};
Velocity = var(1);
Angle_of_Attack=var(2);
Pitch_Angle=var(3);
Pitch_Rate=var(4);
Load_Factor=var(5);
Normal_Acceleration=var_one(5)*g^2;
Variance_Table = table(Velocity, Angle_of_Attack, Pitch_Angle, Pitch_Rate, Load_Factor,Normal_Acceleration, 'RowNames', LastName)

Antworten (1)

Sean de Wolski
Sean de Wolski am 17 Mär. 2017
LastName = {'Analyical PSDs'; 'Experimental Non-smoothed Periodograms'; 'Experimental Smoothed Peridograms'; 'Time Traces'};
Variance_Table = table(rand(4,1), 'RowNames', LastName)
Works for me... What is the error message? Are you sure those variables have four rows?

Kategorien

Mehr zu Tables finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by