convert_to_SE: Convert an rbiom object to a SummarizedExperiment object.

convert_to_SER Documentation

Convert an rbiom object to a SummarizedExperiment object.

Description

Requires the relevant Bioconductor R package to be installed:

Usage

convert_to_SE(biom)

convert_to_TSE(biom)

Arguments

biom

An rbiom object, such as from as_rbiom(). Any value accepted by as_rbiom() can also be given here.

Details

A SummarizedExperiment object includes counts, metadata, and taxonomy.

TreeSummarizedExperiment additionally includes the tree and sequences.

Value

A SummarizedExperiment or TreeSummarizedExperiment object.

Examples

    
    library(rbiom) 
    
    print(hmp50)
      
    # Requires 'SummarizedExperiment' Bioconductor R package
    if (nzchar(system.file(package = "SummarizedExperiment"))) {
      se <- convert_to_SE(hmp50)
      print(se)
    }
      
    # Requires 'TreeSummarizedExperiment' Bioconductor R package
    if (nzchar(system.file(package = "TreeSummarizedExperiment"))) {
      tse <- convert_to_TSE(hmp50)
      print(tse)
    }

cmmr/rbiom documentation built on April 28, 2024, 6:38 a.m.