-
Notifications
You must be signed in to change notification settings - Fork 2
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 SingleR and CellAssign metadata #388
Conversation
Just noting that this has now been tested and works successfully. The saved celldex refs can be found in the |
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.
Looks good overall! I mostly have organizational and naming comments. Note that I did not test this myself at this stage, but plan to do so on 2nd round of review (also in part to test that all the suggestions, should you decide to accept them, are ok!).
- Since
references
now contains references of two different flavors for for two different workflows (e.g. transcriptome references vs cell type annotation references), time to add a quickreferences/README.md
. (Later, we'll want more docs about, for example, adding more references to this workflow; can we open an issue for that?) For thisREADME.md
, here's some particular aspects I think we should make sure are there, beyond the baseline "what are these files" content -- Indicate that the
organ
column incelltype-reference-metadata.tsv
has relevant values from theorgan
column in the PanglaoDB - References (no pun intended, probably, ok maybe a little) for
celldex
andPanglaoDB
- Indicate that the
- I'm not sure the variable name (and its "downstream" variables
celltype_ref_database
) is the right name here, sincecelldex
isn't exactly a database (though PanglaoDB is). I wondered if "source" might be a better overall term here? If you agree, I've made suggestions throughout to use the term "source" instead of "database", e.g.celltype_ref_source
in the TSV andref_source
in the workflow. Or, if you strongly disagree, I'm not offended if you resolve/ignore all these suggestions! - I wonder if we want real params for
singler_models/
andsingler_references/
paths, e.g.This will make our lives easier should these values ever have to change, since it would all be defined in the references config and not directly within the workflow# path in save_singler_refs() process params.singler_references_dir = "${params.celltype_ref_dir}/singler_references" # path in train_singler_models() process params.singler_models_dir = "${params.celltype_ref_dir}/singler_models"
Co-authored-by: Stephanie <stephanie.spielman@gmail.com>
I definitely agree we need docs, but I think that it makes more sense to do it in a separate issue, so I filed #389.
I liked this idea! So I went ahead and took your suggestions. I knew
I had thought about this and was on the fence a lot. But I think you're right that changing them later will be easier to manage by making them params. Additionally, I would like to ultimately make a @sjspielman This is ready for another look. |
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.
LGTM! I just ran build-celltype-ref.nf
, and all looks as expected in s3://scpca-references/celltype
. My only comment is...
Additionally, I would like to ultimately make a json file to hold the refs/paths that we have for cell typing just like we do for the regular workflow.
Makes sense to me! Should this be an issue too (and we do should it come before or after #389? - your call!)?
Closes #279 and starts to address #384
As I started to work on #384, the first thing that I had to figure out was how we are going to store the metadata for the references used with
CellAssign
, and how will that relate to the way we currently store the references forSingleR
. Previously, we had been keeping a list of references to use withSingleR
inScPCA-admin
, but there is no reason to me why the list of available references for use with the workflow should be there and not in this repo. This is similar to the metadata we now have for which references are available for single-cell (ref-metadata.tsv
). That data is stored in thereferences
folder as part of the repo, so here I am porting over thecelltype-reference-metadata.tsv
and making follow-up changes to account for that.SingleR
andCellAssign
, I added in new columns to account for thecelltype_method
. Now we are storing both what package/ database the references come from and the cell type method. I use that column to split the channel in the workflow.organs
column that will be used to indicate whichorgans
fromPanglaoDB
should be grouped for eachref_name
/ tissue type. I includedmuscle
,brain
, andblood
right now as those are the most straight forward to me and probably going to be the most highly used refs anyways.celldex
and save them (as was the original purpose of Create independent workflow for grabbing and saving refs for SingleR #279). The output is therds
file containing thecelldex
reference and becomes the input to the training process we already had.CellAssign
and addressing Process for creating marker gene refs to use with CellAssign #384, I created the channel that will become input to a process for generating marker gene reference matrices. I plan on creating the process and the script that gets run to build the marker gene matrices as a separate PR.references
folder.celldex
to be part ofscpcaTools
. Once that is in, I can test this and request a formal review.