#' Concatonate factors
#'
#' This function will take two different factors of the form `class(factor)`,
#' and will concatonate such factors using internal indexing.
#'
#' @param a of the class `class(factor)`
#' @param b of the class `class(factor)`
#'
#' @return A `factor()` class object
#' @export
#' @examples
#' fac_bind(iris$Species[c(1,51,101)], PlantGrowth$group[c(1,11,21)])
fac_bind <- function(a,b) {
factor(c(as.character(a), as.character(b)))
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.