Hi,
I'm using Diffbind for obtaining differential binding patterns for a bunch of samples. I was wondering how I could have all the samples in the correlation heatmap while using the contrast option on a subset of samples. I would like to see the correlation map between all the samples while using only the peaks deferentially bound between a subset of samples. Here is my script:
ESR1_mutation_db_T47D <- dba(sampleSheet="C:/Users/seb10/Box Sync/esr1-mut/ChIP-seq data/Diffbind/Running_DiffBind/Meta_data_T47D.csv") ESR1_mutation_cr_T47D <- dba.count(ESR1_mutation_db_T47D, summits = 228) ESR1_mutation_dba_vehWT_vs_vehMut_T47D <- dba.contrast(ESR1_mutation_cr_T47D, group1 = ESR1_mutation_cr_T47D$masks$`WT-V`, group2 = ESR1_mutation_cr_T47D$masks$Mut) ESR1_mutation_dba_vehWT_vs_Mut_T47D <- dba.analyze(ESR1_mutation_dba_vehWT_vs_Mut_T47D) dba.plotHeatmap(ESR1_mutation_dba_vehWT_vs_Mut_T47D, contrast=1, th=1, ColAttributes = DBA_CONDITION, RowAttributes = DBA_CONDITION)
And here is my contrast:
> ESR1_mutation_dba_vehWT_vs_Mut_T47D
6 Samples, 3480 sites in matrix:
ID Tissue Factor Condition Treatment Caller Intervals FRiP
1 T47D-WT-V WT ER WT-V Vehicle counts 3480 0.00
2 T47D-WT-E WT ER WT-E E2 counts 3480 0.01
3 T47D-Y537S-V Mut ER Y537S-V Vehicle counts 3480 0.00
4 T47D-Y537S-E Mut ER Y537S-E E2 counts 3480 0.01
5 T47D-D538G-V Mut ER D538G-V Vehicle counts 3480 0.00
6 T47D-D538G-E Mut ER D538G-E E2 counts 3480 0.03
1 Contrast:
Group1 Members1 Group2 Members2 DB.DESeq2
1 group1 1 group2 4 46
In this case if I plot the "ESR1_mutation_dba_vehWT_vs_Mut_T47D", it only shows me 5 samples which are present in the contrast. Please let me know if you need other information.
Thanks
Amir
Thanks Rory, very well explained!
Best
Amir