gtf2table: Convert an annotation file in GTF format in tabular format as...

Description Usage Arguments Details Value Examples

View source: R/gtf2table.R

Description

gtf2table This function converts coding sequence annotation from GTF format to tabular format as required for RiboVIEW. In case GTF file format differs slightly from the expected, options endindside1, etc. allow to adjust this script. This should be facilitated using verbose=TRUE. Also, this home-made GTF parser is typically not very robust to unexpected characteristics in the attributes field (9th field, containing several semicolon-separated attributes). In this case, setting verbose=TRUE will help settling the problem.

Usage

1
2
3
gtf2table(refGTF, outfile,  
          endinside1 = 1, stopoutside1 = 1, stopminusoutside1 = 1,
          verbose=FALSE)

Arguments

refGTF

Coding sequence annotation in GTF format

outfile

File name for output file in tabular format

endinside1

Optional indicator, 0 if field end (5' side) is first base outside of feature, in GTF file, 1 if field end (5' side) is last base in feature (exon, CDS, transcript, etc.).

stopoutside1

Optional indicator, 0 if stop is included in CDS, in GTF file, in '+' strand case. 1 if stop is outside the CDS as annotated in GTF file, in '+' strand case.

stopminusoutside1

Optional indicator, 0 if stop is included in CDS, in GTF file, in '-' strand case. 1 if stop is outside the CDS as annotated in GTF file, in '-' strand case.

verbose

Print or not detailed messages (defaults to FALSE).

Details

This function relies on Python script gtf2table.py.

Value

Output file with CDS annotation in tabular format is written to the file name "outfile".

Examples

1
2
3
4
5
6
refGTF <- paste(system.file(package="RiboVIEW", mustWork = TRUE), "/extdata/example.gtf.gz", sep="")
refCDS <- tempfile()
gtf2table(refGTF, outfile = refCDS)

cds <- read.table(refCDS)
head(cds)

carinelegrand/RiboVIEW documentation built on July 17, 2020, 3:02 p.m.