Description Usage Arguments Value Author(s) Examples
View source: R/create-coverage-matrix.R
Create normalized data frame from input coverage bed files The function will read in bed files, coverage column will be specified by user and collate them to make a data matrix and then normalize by the library size. If the library sizes are not provided by then use sum of reads across loci as proxy. Though this is not recommended.
1 2 | createCoverageMatrix(inputPath, filePattern, junctionReads, junctionType,
promoterFile, gencodefile, normalize, librarySizeFile, ...)
|
inputPath |
Path to coverage or junction bed files. Assumptions for coverage bed file - 1st 3 columns are the loci of interest (chr start stop) and the last column is the coverage readcount |
filePattern |
character string or regular expression to search inputPath to get all coverage files |
junctionReads |
logical flag specifying whether junction reads are to be calculated OR not |
junctionType |
character type of the junction bed file. Either 'tophat' or 'star' |
promoterFile |
Full path file name of promoter loci - needs to be a bed file if junctionReads flag is equal to TRUE |
normalize |
logical flag specifying whether normalization by library size should be done or not |
librarySizeFile |
full path file name with library sizes. Should have two columns 1st should be sample name - same as file name in @param inputPath and the 2nd as the library size. No of rows should be equal to no of coverage files read from @param inputpath |
A data.frame object with normalized RNAseq reads in each sample (rows)
Aditi Qamra
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | ## Not run:
norm_matrix <- createCoverageMatrix(inputPath="readcount/",
filePattern="coverage_",
junctionReads=FALSE,
junctionType='',
promoterFile='',
normalize=TRUE,
librarySizeFile="libsizes.txt")
norm_matrix <- createCoverageMatrix(inputPath="test/",
filePattern=".junction.bed",
junctionReads=TRUE,
junctionType='tophat',
promoterFile='test/aploci.bed',
normalize=TRUE,
librarySizeFile="libsizes.txt")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.