Skip to content
This repository has been archived by the owner on Jun 21, 2023. It is now read-only.

Include neutral changes in cnv consensus .seg file #476

Merged

Conversation

jashapiro
Copy link
Member

@jashapiro jashapiro commented Jan 24, 2020

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

  • This analysis module has a README and it is up to date.
  • This analysis is recorded in the table in analyses/README.md and the entry is up to date.
  • The analytical code is documented and contains comments.

Duong and others added 30 commits December 18, 2019 03:51
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.
@jashapiro jashapiro mentioned this pull request Jan 24, 2020
3 tasks
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 jashapiro force-pushed the jashapiro/fill-segfile-neutral branch from 1f249e2 to 710f51a Compare January 24, 2020 22:23
Put all intermediate files in a defined scratch sub directory.
Copy link
Member

@jaclyn-taroni jaclyn-taroni left a 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,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this used anywhere?

Copy link
Member Author

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.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants