Extracts promoter sequences from input bed/gff file
get_promoter_from_feature( feature_file, fasta_file, write_outputfasta = FALSE, write_promoterbed = FALSE, upstream_bp = 500, downstream_bp = 1 )
feature_file | Either a path or a connection to either
a bed file, file format should be standard UCSC bed format with column:
|
---|---|
fasta_file | Either a path or a connection to reference multi-fasta file, from which subset of sequences for given input list is to be retrieved. In the sequence header: only string before first space and/or first colon (:) will be considered for further processes. **Important consideration when header have long names. |
write_outputfasta | Logical, to return promoter sequences as a output multi-fasta file, Default: FALSE |
write_promoterbed | Logical, to return promoter regions as a output bed file, Default: FALSE |
upstream_bp | numeric, base pairs window upstream of start coordinate, Default: 500 |
downstream_bp | numeric, base pairs window downstream of start coordinate, Default: 1 |
sequences of promoters and bed file of the promoter region
if (FALSE) { feature_file_in <- system.file("exdata","Sc_ref_genes.gff", package = "fastaR") ref_fasta <- system.file("exdata", "Sc_ref_genome.fasta", package = "fastaR") fastaR::get_promoter_from_feature(feature_file=feature_file_in, fasta_file=ref_fasta, write_outputfasta= FALSE, write_promoterbed= FALSE, upstream_bp= 1000, downstream_bp= 100) }