readGMAP: Read the pairwise sequence alignments from a file.

Description Usage Arguments Value Examples

View source: R/AStrap.R

Description

This functions is a container for storing pairwise sequence alignments in a cluster.

Usage

1
2
readGMAP(gmap.path, cdhit.result, recluster = TRUE,
  recluster.identity = 0.7, recluster.coverage = 0.7)

Arguments

gmap.path

A string for the name of a GFF3 file of pairwise sequence alignments output by GMAP.

cdhit.result

A data frame holds isoform clusters.

recluster

To obtain all potential clusters with more than one isoform for further analysis, a second-round mapping can be performed on clusters with single isoform. If TRUE (default), isoforms passing the second-round mapping were reassigned to the corresponding new clusters.

recluster.identity

An numeric value indicating the threshold of identity of alignment for the second-round mapping (default: 0.7). Used only if recluster = TRUE.

recluster.coverage

An numeric value indicating the threshold of coverage of alignment for the second-round mapping (default: 0.7). Used only if recluster = TRUE.

Value

A list contation the pairwise sequence alignments in a cluster, including two elements: alignment and cluster. alignment is a data frame storage the pairwise alignment of isoforms in a cluster; cluster is a data frame storage the new clustering result after second-round mapping.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
##Load the example data
cdhit.path <- system.file("extdata","example_cdhitest.clstr",package = "AStrap")
gmap.path <- system.file("extdata","example_gmap.gff3",package = "AStrap")

##Read raw isoform clusters
raw.cluster <- readCDHIT(cdhit.path)

##Pairwise sequence alignments of isoforms of the same cluster.
cluster.align <- readGMAP(gmap.path,raw.cluster, recluster = TRUE,
                          recluster.identity = 0.7,
                          recluster.coverage = 0.7)
##Pairwise sequence alignments
alignment <- cluster.align$alignment
head(alignment[,1:4])
##Adjusted cluster
rew.cluster <- cluster.align$cluster

BMILAB/AStrap documentation built on Nov. 20, 2020, 4:03 p.m.