roland-rad-lab / MoCaSeq

Analysis pipelines for cancer genome sequencing in mice.
Other
21 stars 15 forks source link

Mistake in CNV_CopywriterGetModeCorrectionFactor.R ? #2

Closed DavideBrex closed 3 years ago

DavideBrex commented 4 years ago

Hi, I was looking at the re-normalization step of your pipeline and I noticed a possible mistake in the script _CNVCopywriterGetModeCorrectionFactor.R . Here:

segmentData$seg.mean = segmentData$Mean-Shift
segmentData=segmentData[,c("Chrom", "Start", "End", "Mean")]

segmentData contains the columns Chrom, Start, End, Mean. The column seq.mean is then added, but in line 26 the table is updated keeping the old Mean column, and not the one with the correction (Mean - Shift). I believe this is a mistake.

Thank you for your nice work.

Best regards

NikdAK commented 3 years ago

Thank you very much for this observation! This is indeed a small mistake and will be fixed in the soon upcoming release.

Here is the solution, in case someone wants to run an analysis right now:

segmentData=segmentData[,c("Chrom", "Start", "End", "seg.mean")]
names(segmentData)[names(segmentData) == "seg.mean"] <- "Mean"