Learn R Programming

bPeaks (version 1.2)

dataReading: Function to import sequencing results in R

Description

Sequencing results should be converted to datafiles with numbers of sequences mapped on each nucleotide in the reference genome. These files can be generated from indexed BAM files (mapping results) using the "genomeCoverageBed" tool available from the BEDTOOLS suite [1]. More information concerning file descriptions can be found online:

http://bpeaks.gene-networks.net/.

File format should be as follows (chromosome, position, number of sequences):

chrI 1
4 chrI
2 4
chrI 3
4 chrI
4 4
chrI 5
7 chrI
6 7
chrI 7
9 chrI
8 9
chrI 9
10 chrI
10 13

Usage

dataReading(IPfile, controlFile, yeastSpecies = NULL)

Arguments

IPfile
Name of the file with sequencing results related to IP sample
controlFile
Name of the file with sequencing results related to control sample
yeastSpecies
Not mandatory. Annotations to be used for locations of peaks in promoters. Annotations of CDS are available in bPeaks for yeasts: Debaryomyces.hansenii, Eremothecium.gossypii, Kluyveromyces.lactis, Pichia.sorbitophila, Saccharomyces.kluyveri, Yarrowia.lipolytica, Zygosaccharomyces.rouxii, Saccharomyces.cerevisiae, Candida.albicans, Candida.glabrata (see data yeastCDS)

Value

A list with three elements ($IPdata, $controlData, $cdsPositions): IP data, control data and (if specified by user) CDS positions for locations of peaks in promoters.

Details

To obtain a required file from a BAM file (resultFile.bam), the command line is (SHELL):

genomeCoverageBed -ibam resultFile.bam -d > resultFile.txt

More information concerning file conversions can be found online:

http://bpeaks.gene-networks.net/.

References

[1] Quinlan AR and Hall IM, 2010. BEDTools: a flexible suite of utilities for comparing genomic features. Bioinformatics. 26, 6, pp. 841 842.

See Also

peakLocation dataPDR1 yeastCDS

Examples

Run this code
# get library
library(bPeaks)

## Not run: 
# # Sequencing result files associated to PDR1 datasets (IP and control files) 
# # can be downloaded from our website http://bpeaks.gene-networks.net/. 
# # They are respectively named "IP_genomeCoverage.txt" (IP sample) and 
# # "INPUT_genomeCoverage.txt" (control sample).
# 
# # Import in R the sequencing results using S. cerevisiae CDS annotations.
# data(yeastCDS)
# seqResult = dataReading("IP_genomeCoverage.txt", "INPUT_genomeCoverage.txt",
# 			yeastSpecies = yeastCDS$Saccharomyces.cerevisiae)
# 
# # IP data
# seqResult$IPdata
# 
# # control data
# seqResult$controlData
# 
# # run peak detection from IP and control data (with default parameters)
# bPeaksAnalysis(IPdata = seqResult$IPdata, 
# 	       controlData  = seqResult$controlData,
# 	       cdsPositions = seqResult$cdsPositions)
# ## End(Not run)

Run the code above in your browser using DataLab