tidyqpcr icon indicating copy to clipboard operation
tidyqpcr copied to clipboard

Support for Taqman / hydrolysis / multi-colour probes

Open ewallace opened this issue 5 years ago • 2 comments

Current edition of tidyqpcr works for SYBR safe experiments, i.e. 1 probe in 1 colour per well. The other major approach to qPCR is hydrolysis probes (TaqMan), which has multiple probes measured in different wavelengths per well. tidyqpcr should cope with this fine, but the plate plans & display_plate will need adapting. We may need a new function to read multicolour data.

Help wanted! Good first issue for someone with Taqman data, especially from a Roche Lightcycler.

ewallace avatar Mar 15 '20 09:03 ewallace

We need a user with multi-colour data in order to make any progress. All the users we have interviewed so far use single-colour qPCR, so this has been a low priority. We emailed some colleagues for help, and can revisit or reprioritise later.

Help wanted - if you want this feature, please get in touch!

ewallace avatar Sep 04 '20 09:09 ewallace

If {tidyqpcr} is to handle multi-colour probes, then, for amplification curves, we will need a tibble with the following columns:

  • plate
  • well
  • fluorophore/probe (or some more generic name that works both for intercalating dyes and probes)
  • cycle
  • fluor

From what I read in your README I know you are trying to stick to tibbles only. But I think it would be very beneficial to use two S3 classes to represent amplification curves and melting curves. They can be built on top of tibbles, and all the logic you have planned will still work. But having a class attribute would allow us to perform checks that inevitably we will have to do. Currently, in your code you seem to be doing these checks by a series of assertions, e.g.:

    assertthat::assert_that(
        assertthat::has_name(
            plateamp,
            c("well", "program_no", "cycle", "fluor_raw"))
    )
    assertthat::assert_that(
        !assertthat::has_name(plateamp,"fluor_base"),
        msg = "plateamp contains a variable called fluor_base, which breaks debaseline"
    )

In the long run I think this will be brittle. So why not just create two S3 classes, perhaps "qpcr_ampl" and "qpcr_melt"? And then have validator functions that check column existence for each for the two types of tibbles?

ramiromagno avatar Oct 30 '22 11:10 ramiromagno