#' Output dictionary
#'
#' A list of all object classes that the single-cell dataset can be returned as.
#' Classes are grouped by families of related classes.
#' @param output_class Name of the output class you wish to produce.
#' Alternatively, set to \code{NULL} to return all possible output classes.
#' @returns A valid \code{output_class}.
#'
#' @export
#' @examples
#' output_class <- dict_output(output_class="seurat")
dict_output <- function(output_class=NULL){
cdict <- dict_class()
output_classes <- list(se=tolower(cdict$se),
hdf5se=tolower(cdict$hdf5se),
seurat=tolower(cdict$seurat),
h5seurat=tolower(cdict$h5seurat),
loom=c("loom"),
list="list"
# anndata=c("anndata","h5ad")
)
if(is.null(output_class)){
return(output_classes)
} else {
output_class <- tolower(output_class)[1]
if(!output_class %in% unname(unlist(output_classes))){
stopper("output_type must be one of the following:",
paste(unname(unlist(output_classes)), collapse = ", "))
} else {
return(output_class)
}
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.