andersen-lab / Freyja

Depth-weighted De-Mixing
BSD 2-Clause "Simplified" License
100 stars 29 forks source link

Question - Running Freyja against older samples #103

Closed gholden3 closed 1 year ago

gholden3 commented 1 year ago

Hi,

If I wanted to run freyja against an older sample, say from before Omicron even, is there a way I can ask freyja to pull the older reference files? Alternatively, is there a way you know of that I could pull the older files myself and process them same as freyja does and then pass them to freyja demix command?

Thanks in advance.

joshuailevy commented 1 year ago

Hey,

Just to clarify, are you looking to get old barcode files that don't have Omicron to see how Freyja responds when Omicron is present in a sample but not in the barcode library? Old barcode libraries can definitely be generated if needed, and for the future I've started regularly pushing updated barcodes once per day to this repo here so users can just grab that (and updates will just require a quick download :) ).

On the other hand, if you're asking if Freyja can demix old samples with old lineage mixtures, no changes should be necessary, as Freyja uses the complete set of known pango lineages every time it runs (and it should have no issues demixing wastewater samples from early in the pandemic, for example).

Josh

gholden3 commented 1 year ago

Got it, so it's the latter. We are running older samples, with the current (today) lineage file, and seeing results that did not exist yet. So you're saying this is unexpected for freyja? Would it help to send you some examples?

joshuailevy commented 1 year ago

Hm. It's entirely possible that you'd see noise/low levels of lineages(1% or less) that weren't yet in existence due to a combination of seq errors and random mutations popping up in the population, but I wouldn't expect more recent lineages to be present.

Yeah, if you can send an example or two, I'd be happy to investigate further.

gholden3 commented 1 year ago

Sure let me get some together.

rpregitzer commented 1 year ago

Good morning,

I work with gholden3 and am passing along the samples she mentioned that were giving us strange outputs. Let us if you have any thoughts on what we're seeing.

Linking a couple of samples below (from NCBI). We are seeing Omicron and/or Delta showing up in the _strain_whoname outputs for these samples: aquavitas_B3 - seeing Omicron at .40567 abundance aquavitas_C3 - seeing Delta at .21000 abundance and Omicron at 0.64902 abundance

Let me know if we can provide more examples. We have a good list to share.

gholden3 commented 1 year ago

@joshuailevy is the above data enough for your debugging purposes? We can provide additional samples, or the actual freyja.demix's if youre unable to reproduce, or any other data you might require. Thanks again for your engagement here.

joshuailevy commented 1 year ago

Hi @gholden3, I think this should probably be sufficient. I'll take a closer look tomorrow.

rpregitzer commented 1 year ago

Hi @joshuailevy,

Did you get a chance to look into this? We still might be having issues here.

Ryan

joshuailevy commented 1 year ago

Hey @rpregitzer,

My apologies, I ended up losing track of this around the holidays. Will try to get around to this ASAP, hopefully tomorrow.

Best, Josh

joshuailevy commented 1 year ago

Finally had a look at these. It looks like you're dealing with a metadata issue here actually, as I'm fairly confident those samples are not actually coming from January of 2020 (almost no one had wastewater surveillance going at that time). Given that these samples were published to NCBI in February of 2022, I'd guess that they're actually from 2022.

Could be worth contacting the authors to confirm that those are the correct dates if those are important samples.

Are there any other samples that you're seeing this on?

Sorry again for the delay!

Josh

joshuailevy commented 1 year ago

Hey @rpregitzer and @gholden3, Are you still having issues with this? The above comment should explain the results for the samples @rpregitzer sent, but let me know if you've got other similar examples. If not, I'll go ahead and close this.

rpregitzer commented 1 year ago

Hey @joshuailevy,

Thanks for the response! This is helpful - we're still trying to see whether we have more samples we need reviewed. Is there any chance you would be willing to grab some time with us if we have further questions and the samples still don't align with what we expect?

Ryan

joshuailevy commented 1 year ago

For sure. Just send me a message at jolevy@scripps.edu and we can set up a time to chat. I'll close this for now, but we can open it back up again if need be.

Best, Josh