My list consist values as shown.
Mylist:
[[1]]
[1] 1 1 1 0 1 1
[[2]]
[1] 0 0 0 0 1 0
[[3]]
[1] 0 0 0 0 1 0
I need to convert this binary values to decimal. I am using BinToDec()
function. But here values are space separated. How to get the values like 111011, 000010 etc in that list. I have tried with gsub
, but it removes spaces in string. Thanks!