Quantcast
Channel: MATLAB Central Newsreader Recent Posts
Viewing all articles
Browse latest Browse all 19628

Re: conversion from double to char

$
0
0
"Timothy Koh" <timothy_koh87@hotmail.com> wrote in message <khk1ff$eur$1@newscl01ah.mathworks.com>...
> Hi
>
> Anyone know how to convert 1 1 1 0 0 0 <1x6 double> to 111000 <1x6 char>?

d = [1 1 1 0 0 0];
c = char(d+'0');

James Tursa

Viewing all articles
Browse latest Browse all 19628

Trending Articles