Concatenation error while defining a cell variable

I am trying to define a cell variable as
col_req = {'columnA', 'ColumnB',
'ColumnC'}
and i get the following error. I don't understand why changing line in code causes this error? If cell values are more I can't fit them in one line causing readability issue.
Dimensions of matrices being concatenated are not consistent.

 Respuesta aceptada

KSSV
KSSV el 25 de Jul. de 2020
Editada: KSSV el 25 de Jul. de 2020
col_req = {'columnA', 'ColumnB', 'ColumnC' }
OR
col_req = {'columnA', 'ColumnB',........
'ColumnC' }

2 comentarios

@KSSV what is the purpose of ...... can you explain?
KSSV
KSSV el 25 de Jul. de 2020
It is to continue your code to next line.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Productos

Etiquetas

Preguntada:

el 25 de Jul. de 2020

Comentada:

el 25 de Jul. de 2020

Community Treasure Hunt

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

Start Hunting!

Translated by