การประเมินการเสริมสมรรถนะ

ChIP-seq with Bioconductor in R

Peter Humburg

Statistician, Macquarie University

ChIP-seq with Bioconductor in R

ChIP-seq with Bioconductor in R

การขยาย reads

โหลดข้อมูล:

reads <- readGAlignments(bam)
reads_gr <- granges(reads[[1]])

หาความยาวเฉลี่ยของ fragment:

frag_length <- fragmentlength(qc_report)["GSM1598218"]

ขยาย reads และคำนวณ coverage:

reads_ext <- resize(reads_gr, width=frag_length)
cover_ext <- coverage(reads_ext)
ChIP-seq with Bioconductor in R

ChIP-seq with Bioconductor in R

Coverage สำหรับ peaks

สร้าง bins ขนาด 200 bp ตลอดจีโนม

bins <- tileGenome(seqinfo(reads), tilewidth=200, 
                   cut.last.tile.in.chrom=TRUE)

หา bins ทั้งหมดที่ซ้อนทับกับ peaks

peak_bins_overlap <- findOverlaps(bins, peaks)
peak_bins <- bins[from(peak_bins_overlap), ]

นับจำนวน reads ที่ซ้อนทับกับแต่ละ peak bin

peak_bins$score <- countOverlaps(peak_bins, reads)
ChIP-seq with Bioconductor in R

ฟังก์ชัน binned coverage

count_bins <- function(reads, target, bins){
  # Find all bins overlapping peaks
  overlap <- from(findOverlaps(bins, target))
  target_bins <- bins[overlap, ]

  # Count the number of reads overlapping each peak bin
  target_bins$score <- countOverlaps(target_bins, reads)
  target_bins
}
ChIP-seq with Bioconductor in R

Coverage สำหรับบริเวณ blacklisted

peak_bins <- count_bins(reads_ext, peaks, bins)
bl_bins <- count_bins(reads_ext, blacklist.hg19, bins)
ChIP-seq with Bioconductor in R

Coverage ของ background

ลบ bins ที่นับแล้วออกทั้งหมด

bkg_bins <- subset(bins, !bins %in% peak_bins & !bins %in% bl_bins)

นับจำนวน reads ที่ซ้อนทับกับแต่ละ bin ที่เหลือ

bkg_bins$score <- countOverlaps(bkg_bins, reads_ext)
ChIP-seq with Bioconductor in R

ChIP-seq with Bioconductor in R

ChIP-seq with Bioconductor in R

ChIP-seq with Bioconductor in R

มาฝึกกันเถอะ!

ChIP-seq with Bioconductor in R

Preparing Video For Download...