MATLAB Answers

0

i have a datset name as dec_table (150,5) and a new_att(150,1) and i want to combine these two to make new_dec_table?

Asked by vinay kumar maddhesia on 29 Oct 2019
Latest activity Edited by Sai Bhargav Avula on 29 Oct 2019
new_dec_table = cat(2,new_att,dec_table);
error:
Error using cat
Dimensions of matrices being
concatenated are not consistent.
Error in iris_rough3 (line 41)
new_dec_table =
cat(2,new_att,dec_table);

  0 Comments

Sign in to comment.

1 Answer

Answer by Sai Bhargav Avula on 29 Oct 2019
Edited by Sai Bhargav Avula on 29 Oct 2019

Hi, In your case horzcat would work.
Try
new_dec_table = horzcat(new_att,dec_table)
This would concatenate horizontally as your data has row consistency

  0 Comments

Sign in to comment.