How do I extract values from array into table

3 vues (au cours des 30 derniers jours)
Thomas Ward
Thomas Ward le 1 Oct 2018

I have a code with four arrays, as follows

deltaC=0:0.1:1;
Xone=ones(1, 11);
Xtwo=zeros(1, 11);
Stwo=ones(1, 11);

I'm trying to put the values into a table, but when I use the code

 T=table(deltaC,Stwo,Xone,Xtwo)

It gives me a 1x4 table with the array names and simply that they are a 1x11 double. What I'm looking for is a 11x4 table that takes the values from the array and lists them in the table. How do I call that?

Réponse acceptée

Matt J
Matt J le 1 Oct 2018
T=table(deltaC.',Stwo.',Xone.',Xtwo.')

Plus de réponses (0)

Catégories

En savoir plus sur Tables dans Help Center et File Exchange

Tags

Produits


Version

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by