how to make a row matrix from matlab generated data.

10 vues (au cours des 30 derniers jours)
SATYA BHATT
SATYA BHATT le 22 Fév 2019
Commenté : Jos (10584) le 22 Fév 2019
Hi all,
I have a matlab code that outputs the reselts in the form of s(:,:,1) = 'value' , s(:,:,2)='value' , s(:,:,3)='value' and so on.
Now, I want to combine all these " S " to form a single row matrix or a single column matrix.
thanks...
  2 commentaires
madhan ravi
madhan ravi le 22 Fév 2019
could you show what
size(s) shows?
whos s
SATYA BHATT
SATYA BHATT le 22 Fév 2019
I am doing it for mXn matrix ( user defined)
for a 2X6 matrix input ,
size(s) shows
ans=1 1 2

Connectez-vous pour commenter.

Réponse acceptée

Jos (10584)
Jos (10584) le 22 Fév 2019
reshape(S,1,[]) % row vector
  1 commentaire
Jos (10584)
Jos (10584) le 22 Fév 2019
You might also be interested in using SQUEEZE.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Creating and Concatenating Matrices dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by