#' conversion from decimal to binary
#'
#' \code{dec2bin(x)} converts decimal to binary
#'
#' @param x is a number
dec2bin<-function(X) {
b=0
while(X%%2^b!=X)b=b+1
a<-2^((b-1):0)
b<-2*a
print(sapply(X,function(Z) paste(as.integer((Z %% b)>=a),collapse="")),quote=FALSE)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.