readTAXset: readTAXset

Description Usage Arguments Examples

View source: R/utils-tax.R

Description

Function to read in data and create a TAXset object

Usage

1
    readTAXset(dirPath, taxfile, namefile, fastafile, qualfile, samplefile, sampleADF, assignmentADF, sADF.names, aADF.names, type, ...)

Arguments

dirPath

The directory path were the datafile are located. This is the current directory by default.

taxfile

The classification file. The default format is RDP's fixed format.

namefile

A names file in the Mothur format. This is used to add removed unique sequences back into the dataset.

fastafile

The fasta file. This is read in by ShortRead.

qualfile

The quality file. This is read in by ShortRead.

samplefile

The sample file. Currently this must be in Mothur format (.groups).

sampleADF

The sample meta data file. This is in AnnotatedDataFrame format.

assignmentADF

The assignment meta data file (the OTU meta data) This is in AnnotatedDataFrame format.

sADF.names

The column of the sampleADF file that has the sample names.

aADF.names

The column of the assignmentADF file that has the assignment names.

type

This is the type of taxfile. By default this is the RDP fixed format. However, if type is changed to anything else the read.table function is used to read in the taxfile. In this case the first column of the taxfile must be the sequence names.

...

Additional arguments passed to read.table to read in the taxfile.

Examples

1
2
3
4
5
6
dirPath <- system.file("extdata/Sogin_2006", package="OTUbase")

## read in data into TAXset object
soginTAX <- readTAXset(dirPath=dirPath, samplefile="sogin.groups", fastafile="sogin.fasta", taxfile="sogin.unique.fix.tax", namefile="sogin.names", sampleADF="sample_metadata.txt")

soginTAX

OTUbase documentation built on Nov. 8, 2020, 8:24 p.m.