Skip to content

Commit

Permalink
How is scaling factor calculated?
Browse files Browse the repository at this point in the history
  • Loading branch information
hongjianjin committed Jul 19, 2021
1 parent 99089cd commit 67d87b9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion R/ChIPseqSpikeInFree.R
Original file line number Diff line number Diff line change
Expand Up @@ -674,7 +674,7 @@ PlotDistr<-function(data, SF="test_SF.txt", prefix="test", xlimMaxCPMW=NULL)
Xbs <- strsplit(meta$TURNS,",")
MAX_CPMW <- max(as.numeric(unlist(lapply(Xbs,'[',3) ))) + 10
}else{
MAX_CPMW <- min(max(x), xlimMaxCPMW)
MAX_CPMW <- min(max(x), xlimMaxCPMW, 80)
}
if (ncol(subsetByAb) == 1) {
totalPages <- 1
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,11 @@ Output will include: (in case that you set `prefix ="test"`)
- **QC**: quality control testing. QC failure indicates poor or no enrichment.
- **SF**: scaling factor. Only sample that passes QC will be given a SF and **NA** indicates sample with poor enrichment. Input sample is not required for SF calculation. Larger scaling factor indicates a lower level of total histone mark and vice versa. For example, H3K27me3 is globally decreased in H3.3 K27M cells compared to WT (**SF, 5.47 vs 1**).
- **TURNS**: the coordinates of two points [Xa, Ya, Xb, Yb] detected in cumulative distribution plot (proportion of reads below CPMW cutoffs) for slope-based SF calculation.

### How is scaling factor calculated?
Given a set of n samples immunoprecipitated with the same antibody, we chose one sample as a reference βr. We derived the scaling factor (S) for any other sample i as Si=βr/βi where βi is the slope of sample i. Since the scaling factor of one specific sample is relative to the reference sample, the value could be changed based on set of samples included in the analysis. The recommended comparison would be of individual samples between different GROUPs but with same ANTIBODY.


### Graphical results
<img align="center" width="900" height="400" src="docs/H3K27me3_Fig1.jpg">

Expand Down

0 comments on commit 67d87b9

Please sign in to comment.