-
Notifications
You must be signed in to change notification settings - Fork 5
Added UMAP Figures #60
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
base: main
Are you sure you want to change the base?
Conversation
to prevent sampling more samples than available
|
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
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.
Pull request overview
Adds a workflow to compute UMAP embeddings from sampled JUMP single-cell data and generate labeled UMAP visualizations (treatment type, anomaly score, control type).
Changes:
- Pin
umap-learnin the conda environment for compatibility with the repo’s scikit-learn version. - Add a notebook + nbconverted Python script to sample per-plate single cells and compute 2D UMAP coordinates.
- Add an nbconverted R script to render and save UMAP figures colored by multiple metadata fields.
Reviewed changes
Copilot reviewed 4 out of 8 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
environment.yml |
Pins umap-learn to a specific version to support the new UMAP computation workflow. |
3.analyze_data/visualize_umaps/nbconverted/compute_plate_umaps.py |
Implements plate sampling + UMAP computation and writes a parquet used for plotting. |
3.analyze_data/visualize_umaps/compute_plate_umaps.ipynb |
Notebook version of the UMAP sampling/computation workflow. |
3.analyze_data/visualize_umaps/nbconverted/visualize_plate_umaps.r |
Generates and saves UMAP plots labeled by treatment type, anomaly score, and control type. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
To help accommodate for overlapping points, consider using some kind of binning (like hexbinning) to represent the colors. This might avoid misinterpretations. This also applies to the other UMAPs.
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.
Consider removing the grid lines (and possibly the numbering and entirety of the plot border) to help keep the focus on the pattern which emerges from the UMAP. Applies to other UMAPs as well.
| replacements = { | ||
| "crispr": "crispr", | ||
| "orf": "orf", | ||
| "compound": "compound", | ||
| } |
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.
Consider using a list instead of a dict if you only use one set of values (these appear to be the same from key to value). Otherwise, consider updating this so either the key or value differ.
|
@MattsonCam I've opened a new pull request, #61, to work on those changes. Once the pull request is ready, I'll request review from you. |
Computed UMAP from sampled JUMP data and visualized UMAPs labeled by different categories.