This repository has been archived by the owner on Jun 21, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 67
Include neutral changes in cnv consensus .seg file #476
Merged
jaclyn-taroni
merged 69 commits into
AlexsLemonade:master
from
jashapiro:jashapiro/fill-segfile-neutral
Jan 27, 2020
Merged
Include neutral changes in cnv consensus .seg file #476
jaclyn-taroni
merged 69 commits into
AlexsLemonade:master
from
jashapiro:jashapiro/fill-segfile-neutral
Jan 27, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Removing `src` directory to unnest `scripts` and adding `ref` directory for genomic info files.
Link and script to process downloaded file for segmental duplciations.
These regions are the ones defined by @hongboxie here: AlexsLemonade#438 (comment) Converted from hg18 to hg38
Note that ordering has changed, but the actual differences between these files should be relatively small other than that. There are changes to the cnv_consensus.tsv file where segments that are not contained within the defined CNV are discarded but might have been retained before.
Neutral segments (copy number 2) are included if they fall within a "callable region" which is one not covered by a large excluded region. When we add these back, we still exclude specimens where more than two callers 'failed' with high numbers of segments
we don't need data types here, so keeping everything as strings simplifies, and removes potential errors from unexpected conversions from int to float
jashapiro
force-pushed
the
jashapiro/fill-segfile-neutral
branch
from
January 24, 2020 22:23
1f249e2
to
710f51a
Compare
Put all intermediate files in a defined scratch sub directory.
jaclyn-taroni
approved these changes
Jan 27, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One question and one typo, but otherwise LGTM 👍
@@ -52,6 +52,8 @@ def remove_dup_null_outside(cell, start, end): | |||
) | |||
parser.add_argument('--file', required=True, | |||
help='path to the file that needs duplicates and NULLs removed') | |||
parser.add_argument('--uncalled', required=False, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this used anywhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No it is not. I had thoughts that I might use it to annotate where there were only two possible callers, but abandoned that plan on some reflection. I'll remove it unless there is some great idea for how to use the information in this step.
Co-Authored-By: Jaclyn Taroni <jaclyn.n.taroni@gmail.com>
2 tasks
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose/implementation Section
What scientific question is your analysis addressing?
GISTIC requires all assayed regions to be included for every sample, so the previous version of
pbta-cnv-consensus.seg
was failing to run. This set of changes is to update the creation of that file to include the full set of "neutral" changes (copy number 2) in the seg file.What was your approach?
Many regions of the genome are excluded from CN calls in the consensus script, so it does not make sense to simply complement the CNV consensus calls to find the neutral regions. Instead, I first created a file of "callable" regions by removing any large segments that were excluded in the CNV consensus calling pipeline, such as telomeres, centromeres, and segmental duplications.
In addition, samples that were filtered out due to high numbers of segment calls are not included in the final .seg file.
What GitHub issue does your pull request address?
#392
#453
Directions for reviewers. Tell potential reviewers what kind of feedback you are soliciting.
Which areas should receive a particularly close look?
Is the process for generating the callable regions reasonable? The size cutoff of 200kb was selected somewhat arbitrarily, with the goal of not creating too many separate segments, as some downstream analysis will filter samples based on segment number, even if most of those segments have copy number 2.
I currently exclude samples where only one caller passed filters, as those can not by definition have any consensus calls (2 callers must agree). However, the samples with only two callers (where one was excluded) are likely to have a different error profile (and probably fewer net calls). Is this something we should flag, and if so how? There does not seem to be much in the way of tumor type bias in this set, which is good.
Is there anything that you want to discuss further?
Some of the changes here depend on file name changes in #467, so that PR should probably be merged in before this one.
Is the analysis in a mature enough form that the resulting figure(s) and/or table(s) are ready for review?
Results
What types of results are included (e.g., table, figure)?
What is your summary of the results?
Reproducibility Checklist
Documentation Checklist
README
and it is up to date.analyses/README.md
and the entry is up to date.