write.files: write.files

Description Usage Arguments Details Value Note Author(s) Examples

Description

Writes table data and sequence in separate files.

Usage

1
write.files(x, path, filename,...)

Arguments

x

caRanges or aaGapSites object for which data is written.

path

Path for writing files.

filename

Basic filename to which suffixes are added.

...

Other arguments passed to "write.table".

Details

There are two files written: A text file with tabulated values from data.frame (separated by ";") and a fasta file which contains the stored dna sequence.

Value

None.

Note

The function tries to create directory 'path' when it does not exist.

Author(s)

Wolfgang Kaisers

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
# A) Read gap-sites from BAM-files
bam<-system.file("extdata","rna_fem.bam",package="spliceSites")
reader<-bamReader(bam,idx=TRUE)
ga<-alignGapList(reader)
bamClose(reader)
# B) Load DNA sequence
dnafile<-system.file("extdata","dna_small.RData",package="spliceSites")
load(dnafile)
# C) Add DNA sequence
lj<-lJunc(ga,featlen=21,gaplen=21,strand='+')
ljc<-lCodons(lj,frame=1,keepStrand=TRUE)
cdr<-dnaRanges(ljc,dna_small)
# D) Translate DNA to amino-acid
ar<-translate(cdr)
# E) Write "ar.csv" and "ar.fa"
# write.files(ar,".","ar")

wokai/spliceSites documentation built on May 4, 2019, 9:46 a.m.