View source: R/integrateInfo.R
integrate_ChIP_RNA | R Documentation |
integrate ChIP-Seq and RNA-Seq data to find TF target genes
integrate_ChIP_RNA(
result_geneRP,
result_geneDiff,
lfc_threshold = 1,
padj_threshold = 0.05
)
result_geneRP |
the simplify result from calcRP_TFHit(report_fullInfo = FALSE) or RP_df <- metadata(fullRP_hit)$peakRP_gene. |
result_geneDiff |
the result from RNA diff result with three column gene_id, log2FoldChange, padj |
lfc_threshold |
the threshold which decide significant genes |
padj_threshold |
the threshold which decide significant genes |
a ggplot object if having significant genes in your result. If not, it will report a data.frame with integrated info.
if (require(TxDb.Athaliana.BioMart.plantsmart28)) {
data("RNADiff_LEC2_GR")
Txdb <- TxDb.Athaliana.BioMart.plantsmart28
seqlevels(Txdb) <- paste0("Chr", c(1:5, "M", "C"))
peak_path <- system.file("extdata", "ChIP.bed.gz", package = "FindIT2")
peak_GR <- loadPeakFile(peak_path)
mmAnno <- mm_geneScan(peak_GR, Txdb)
result_geneRP <- calcRP_TFHit(
mmAnno = mmAnno,
Txdb = Txdb
)
# output a plot
merge_data <- integrate_ChIP_RNA(
result_geneRP = result_geneRP,
result_geneDiff = RNADiff_LEC2_GR
)
# if you want to extract merge target data
target_data <- merge_data$data
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.