LoadTrackFile.Rd
Load Track File to Dataframe.
LoadTrackFile( track.file, track.folder = NULL, format = c("bam", "wig", "bw", "bedgraph", "txt"), region = "chr14:21,677,306-21,737,601", extend = 2000, gtf.gr = NULL, gene.name = "HNRNPC", gene.name.type = c("gene_name", "gene_id"), meta.info = NULL, meta.file = "", bamcoverage.path = NULL, norm.method = c("RPKM", "CPM", "BPM", "RPGC", "None"), single.nuc = FALSE, single.nuc.region = NULL, bin.size = 10, bc.extra.para = NULL, n.cores = 1 )
track.file | Track file, when |
---|---|
track.folder | Track file folder. Default: NULL. |
format | Track file format, chosen from bam, wig, bw(bigwig), bedgraph(bedGraph) and txt. |
region | Region used to create coverage plot, eg: chr14:21,677,306-21,737,601 or chr14:21,677,306. Default: "chr14:21,677,306-21,737,601" |
extend | Extend length of |
gtf.gr | Granges object of GTF, created with |
gene.name | The name of gene. Default: HNRNPC. |
gene.name.type | Gene name type (filed of |
meta.info | Track file metadata. The columns should be: SampleName ( |
meta.file | File contains track file metadata. Default: "". |
bamcoverage.path | The path to |
norm.method | Methods to normalize the number of reads per bin, chosen from "RPKM", "CPM", "BPM", "RPGC", "None". Default: RPKM. |
single.nuc | Logical value, whether to visualize at single nucleotide level. Default: FALSE. |
single.nuc.region | Region for |
bin.size | Size of the bins, in bases. Default: 50. |
bc.extra.para | Extra parameters for |
n.cores | The number of cores to be used for this job. Default:1. |
A dataframe.
library(ggcoverage) library(utils) meta.file <- system.file("extdata", "RNA-seq", "meta_info.csv", package = "ggcoverage") sample.meta <- utils::read.csv(meta.file) # track folder track.folder <- system.file("extdata", "RNA-seq", package = "ggcoverage") # load bigwig file track.df <- LoadTrackFile( track.folder = track.folder, format = "bw", region = "chr14:21,677,306-21,737,601", extend = 2000, meta.info = sample.meta )