Effacer les filtres
Effacer les filtres

Error using vertcat Dimensions of arrays being concatenated are not consistent.

1 vue (au cours des 30 derniers jours)
Hi everyone. I need to use SVM for prediction. hence, i need to combine my data
data1= 22x 7
data2 = 22 x 8
I dont know how to combine these two data . I used data3=[data1;data2], it does not work . Giving the error mentioned in title

Réponse acceptée

the cyclist
the cyclist le 5 Juin 2021
data3 = [data1 data2]
will concatenate them horizontally rather than vertically. You can do that, because they have the same number of rows. You cannot do your way, because they do not have the same number of columns.

Plus de réponses (0)

Catégories

En savoir plus sur Matrices and Arrays 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