Borrar filtros
Borrar filtros

How to merge two cells and extract the superlayed values?

1 visualización (últimos 30 días)
Native
Native el 4 de Dic. de 2018
Comentada: madhan ravi el 4 de Dic. de 2018
I have two cells of dimensions 1X132 each, one cell has the names and the other has numerical values that correspond to each of those names. I want to be able to merge these two cells such that I can later extract the names corresponding to those values, and preferably display it in a plot

Respuesta aceptada

madhan ravi
madhan ravi el 4 de Dic. de 2018
Editada: madhan ravi el 4 de Dic. de 2018
a=[[cell1{:}] [cell2{:}]]; % cell1 containng names and the other values
plot([cell2{:}])
xticks(1:numel([cell1{:}]))
xticklabel([cell1{:}]) % requires 2016b and later
  7 comentarios
Native
Native el 4 de Dic. de 2018
I use 2015a version of matlab, xticks doesnt work for it

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Logical en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by