水静流深 wrote:
i have write a function to convert decimal number into binary number in R.
dectobin can get right result ,it is so long ,is there a build-in function to
do ?
Try the R.utils package:
> library(R.utils)
> intToBin(12)
[1] "1100"
> intToBin(255)
[1] "11111111"
> intToBin(65535)
[1] "1111111111111111"
> intToBin(65536)
[1] "10000000000000000"
Earl F Glynn
Principal Programmer/Analyst
Center for Health Insights • University of Missouri – Kansas City
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.