export_env_file {phyloseq} | R Documentation

## Export environment (ENV) file for UniFrac Server.

### Description

Creates the environment table that is needed for the original UniFrac algorithm. Useful for cross-checking, or if want to use UniFrac server. Optionally the ENV-formatted table can be returned to the `R` workspace, and the tree component can be exported as Nexus format (Recommended).

### Usage

    export_env_file(physeq, file = "", writeTree = TRUE, return = FALSE)

### Arguments

`physeq` | (Required). Experiment-level (`phyloseq-class`) object. Ideally this also contains the phylogenetic tree, which is also exported by default.
`file` | (Optional). The file path for export. If not-provided, the expectation is that you will want to set `return` to `TRUE`, and manipulate the ENV table on your own. Default is `""`, skipping the ENV file from being written to a file.
`writeTree` | (Optional). Write the phylogenetic tree as well as the the ENV table. Default is `TRUE`.
`return` | (Optional). Should the ENV table be returned to the R workspace? Default is `FALSE`.

### Examples

    # # Load example data
    # data(esophagus)
    # export_env_file(esophagus, "~/Desktop/esophagus.txt")

[Package phyloseq version 1.32.0 Index]