get.fasta: Generating sequences from the reference genome with specific...

Description Usage Arguments Value Examples

View source: R/FcircSEC.R

Description

This function can extract the sequences from the reference genome for the given intervals (start, end) of chromosomes

Usage

1
get.fasta(ref_genome, circ_class_bed, out_filename)

Arguments

ref_genome

The reference genome

circ_class_bed

The bed file having chromosome, start and end position of each circRNAs (obtained from function circClassification)

out_filename

The name of the output file

Value

The fasta file of the sequences extracted from the reference genome for the given intervals will be written in the output file 'out_filename'

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
#Loading an example reference genome and write to a file
#Here temporary directory is created as input-output
#directory. Please provide you own directory instead.
out_dir<-tempdir()
ref_genom<-data("chr1")
ref_genom<-chr1
df.fasta=dataframe2fas(ref_genom, file.path(out_dir, "ref_genome.fasta"))

#Loading an example circRNA classification bed file and write to a file
circ_class_bed<-data("circRNA_classb")
circ_class_bed<-circRNA_classb
write.table(circ_class_bed, file.path(out_dir, "circ_class.bed"), 
    col.names=FALSE, row.names=FALSE)

#Getting genomic sequences of circRNAs. The output will be 
#generated in file circRNA_genomic_seq.fasta in out_dir directory
get.fasta(file.path(out_dir, "ref_genome.fasta"), 
   file.path(out_dir, "circ_class.bed"), 
   file.path(out_dir, "circRNA_genomic_seq.fasta"))

FcircSEC documentation built on Jan. 31, 2020, 5:07 p.m.

Related to get.fasta in FcircSEC...