Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to color by per-base quality in alignment tracks #1601

Merged
merged 1 commit into from
Feb 19, 2021

Conversation

cmdcolin
Copy link
Collaborator

@cmdcolin cmdcolin commented Jan 6, 2021

Draft PR for doing color-by-base-quality

This definitely creates a high density of information but it can be pretty cool

This has to layer the per base quality on top of a drawn rectangle here for it to still have the strand arrows

localhost_3000__config=test_data%2Fconfig_demo json session=local-7n-W2YrL4

@codecov
Copy link

codecov bot commented Jan 6, 2021

Codecov Report

Merging #1601 (ff463e6) into master (708bafa) will decrease coverage by 0.06%.
The diff coverage is 71.92%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1601      +/-   ##
==========================================
- Coverage   58.90%   58.83%   -0.07%     
==========================================
  Files         446      448       +2     
  Lines       20467    20510      +43     
  Branches     4824     4832       +8     
==========================================
+ Hits        12057    12068      +11     
- Misses       8112     8142      +30     
- Partials      298      300       +2     
Impacted Files Coverage Δ
packages/core/util/offscreenCanvasPonyfill.js 14.75% <0.00%> (-0.51%) ⬇️
...lugins/alignments/src/LinearPileupDisplay/model.ts 74.69% <0.00%> (-0.94%) ⬇️
...ns/alignments/src/PileupRenderer/PileupRenderer.ts 65.97% <73.91%> (-6.04%) ⬇️
...ignments/src/PileupRenderer/PileupLayoutSession.ts 100.00% <100.00%> (ø)
plugins/alignments/src/PileupRenderer/util.ts 100.00% <100.00%> (ø)
...inearGenomeView/components/RefNameAutocomplete.tsx 89.36% <0.00%> (-4.26%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 708bafa...ff463e6. Read the comment docs.

@cmdcolin cmdcolin marked this pull request as draft January 6, 2021 17:57
@garrettjstevens garrettjstevens added the needs label triage Needs a label to show in changelog (breaking, enhancement, bug, documentation, or internal) label Jan 6, 2021
@cmdcolin cmdcolin added enhancement New feature or request and removed needs label triage Needs a label to show in changelog (breaking, enhancement, bug, documentation, or internal) labels Jan 8, 2021
Take into account CIGAR string when doing color by base quality

Avoid duplicate fill if possible in offscreenCanvasPolyfill
@cmdcolin
Copy link
Collaborator Author

Refreshed this PR...it should be functional and it actually needed to take the CIGAR string into account e.g. when plotting qual, if there is an insertion in the read, then we increment the position in the qual buffer, but not in the position on the reference genome because the qual contains data on the bases in the insertion

Given the number of coloring options, we may be coming upon a need to make plugins for this function, but there is a wide variety of needs for each type or coloring option so want to commit to the right abstraction

I had also considered trying to add methylation for example but this one is interesting because to really do this one right you really want to integrate with SNPCoverage so that the SNPCoverage keeps track of the methylation at each point

@cmdcolin cmdcolin marked this pull request as ready for review February 16, 2021 21:33
@rbuels rbuels changed the title Color by per-base quality Add ability to color by per-base quality in alignment tracks Feb 19, 2021
@rbuels rbuels merged commit 9a8d75a into master Feb 19, 2021
@rbuels rbuels deleted the color_by_base branch February 19, 2021 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants