uniquefasta: Deleting duplicated sequences in fasta object

Description Usage Arguments Value Note Author(s) References See Also Examples

View source: R/uniquefasta.R

Description

This function may be used to deleting the duplicated sequences in the fasta object. The sequences with its name same to any sequences will be ignored. Only the first sequence will be retained.

Usage

1
uniquefasta(fasta)

Arguments

fasta

The fasta object

Value

This function returns to the fasta object with unique sequence.

Note

This function will remove the duplicated sequences and retain the first sequence only, all according to the names of the sequences.

Author(s)

Jinlong Zhang [email protected]

References

None

See Also

unique

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
library(seqRFLP)
## loading data
data(fil.fas)
## Get the names of the sequences
fasta.names <- gnames.fas(fil.fas)
new.names0 <- substring(fasta.names,1,2 )
new.names <- paste(new.names0, sep = "")
reftable.rename <- data.frame(fasta.names, new.names)
renamed <- rename.fasta(fil.fas, reftable.rename)
uniquefasta(renamed)

phylotools documentation built on May 29, 2017, 1:41 p.m.