Quantcast
Channel: Active questions tagged r - Stack Overflow
Viewing all articles
Browse latest Browse all 201867

concatenate a string into a numeric vector

$
0
0

Suppose I have a long string of numbers "1010101010101010100011011". I would like to separate them by a "," like so "1,0,1,0,1,0,1,1,..." and then transform into a numeric vector like this c(1,0,1,0,1,...).

What would be a smart way to do that ?


Viewing all articles
Browse latest Browse all 201867

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>