Borrar filtros
Borrar filtros

I need to convert the number {11.741677 ] to {11741677} without the point

5 visualizaciones (últimos 30 días)
Dear all, I I need to convert the vector
{11.741667 3.913892 14.488700 8.746350 0.349066}
to integer numbers
{11741667 3913892 14488700 8746350 0349066}
thanks in advance, I really appreciate your help.

Respuesta aceptada

Patrik Ek
Patrik Ek el 7 de Ag. de 2014
Editada: Patrik Ek el 7 de Ag. de 2014
It is always possible to go the long way around here.
a = {11.741667 3.913892 14.488700 8.746350 0.349066};
str = cellfun(@num2str,a,'un',false);
str = strrep(str,'.','');
myStream = horzcat(str{:});

Más respuestas (0)

Categorías

Más información sobre Data Type Conversion en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by