Skip to content

Davereinhart/protein visualization #417

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

Draft
wants to merge 46 commits into
base: release-2025.3.0
Choose a base branch
from

Conversation

davereinhart
Copy link

Add protein visualization component using PDBe-molstar and display alongside scoreset heatmap with interaction between the two to highlight residues on protein model and corresponding heatmap columns. Currently relies on UniProt ID provided by user on upload, but will eventually use UniProt ID determined by mapper function.

… zoom and highlight corresponding residues on ProteinStructureView, plus cleanup of unused code, renaming variables for readability.
…ed residue; add tooltip with mean, min and max scores
…add variable and getter to track last selected DOM coordinates to support programatically zooming to selected range
… of wrapper div, to ensure data being selected is in view
…ent, use click to highlight relevant column in score set heatmap
@bencap bencap changed the base branch from main to release-2025.3.0 June 27, 2025 16:32
@bencap bencap self-requested a review June 27, 2025 16:32
@bencap bencap linked an issue Jun 27, 2025 that may be closed by this pull request
…alizer

The use of d3.select(...) instead of svg.select(...) was causing selecting the wrong element when there are two heatmaps present in the DOM. This is the case with the ScoreSetVisualizer component which contains a heatmap and is being shown as a modal on top of ScoreSetView which also contains a heatmap.
…labels and legend are still visible when scrolling right
…culation for static y-axis SVG

This allows the height of the stacked heatmap to be determined when the main heatmap is added, in order to provide correct top paddding for y-axis SVG that has absolute positioning.

Also removes unused styles.
…VG with absolute position

Replaces hard-coded values with calculated values based on bounding rects of appropriate elements. Also removes unused SVG elements from both the primary `svg` and `yAxisSvg`. Renames classes to remove references to "sticky" because absolute positioning is being used instead (and to match corresponding class names in main svg).
…d on presence of "exclude-from-export" class name

Also applies this class name to yAxisSvg element of scoreset heatmap, which contains duplicate content that is already in main svg element.
In some cases, the presence of heatmap tooltip causes the dynamic height to be calculated incorrectly, resulting in extra empty space below the heatmap and triggering the vertical scroll behavior. This change prevents vertical scrolling in all cases, relying on the scroll container height calculation to match the heatmap height.
…ull-width unicode characters

The minus and equals signs were not sized correctly on the scoreset heatmap using because the style was not being applied. This change removes that and instead uses the full-width unicode character codes, similar to what is already used for the asterick tick label.
…wn, to prevent duplicate heatmaps in the DOM causing issues related to SVG elements with z-index
…row clicked to be handled by parent component.
This change handles the selection of a scoreset row when the y-axis tick label is clicked to color the protein visualization by the scores for a particular amino acid. This selectionData prop passed to the visualization component now includes scores and colors for each row, in addition to the mean, min and max. A watcher has been added to the `colorBy` ref to switch between the different color schemes, which maps the selectionData prop values to the format expected by the PDBe-molstar viewer instance.
@davereinhart davereinhart marked this pull request as draft July 7, 2025 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Protein Structure Visualizer
1 participant