Skip to contents

Calculate library PCR concentrations

Usage

pcr_lib_calc(tidy_pcr, dil_factor = 1000)

Arguments

tidy_pcr

an output of pcr_tidy

dil_factor

integer. The factor to which the libraries were diluted for pcr

Value

a tibble, containing the input columns as well as:

  • standard_diff The difference between the ct_mean of a standard and one step up in the dilution (ie more concentrated, lower Ct). The most concentrated dilution has a value of 0

  • dil 2^(standard_diff). The accuracy of this metric assumes that the efficiency of the PCR is 100%, which is likely good but not perfect!. In the case of the first standard, dil = 0

  • quant_actual For standards, the presumed quantity of standard, calculated from dil. For samples, quantity

  • concentration The concentration of library, before dilution

Examples


system.file("extdata", "untidy-standard-curve.xlsx", package = "amplify") |>
  pcr_tidy(pad_zero = TRUE) |>
  pcr_lib_calc()
#> # A tibble: 58 x 35
#> # Groups:   task [3]
#>    omit  sample_name target_name task     reporter quencher ct_mean    ct_sd
#>    <lgl> <chr>       <chr>       <chr>    <chr>    <chr>      <dbl>    <dbl>
#>  1 FALSE NA          Target 1    NTC      FAM      NFQ-MGB     NA   NA      
#>  2 FALSE NA          Target 1    NTC      FAM      NFQ-MGB     NA   NA      
#>  3 FALSE NA          Target 1    NTC      FAM      NFQ-MGB     NA   NA      
#>  4 FALSE Standard 01 Target 1    STANDARD FAM      NFQ-MGB     15.4  0.0726 
#>  5 FALSE Standard 01 Target 1    STANDARD FAM      NFQ-MGB     15.4  0.0726 
#>  6 FALSE Standard 01 Target 1    STANDARD FAM      NFQ-MGB     15.4  0.0726 
#>  7 FALSE Standard 02 Target 1    STANDARD FAM      NFQ-MGB     18.7  0.00751
#>  8 FALSE Standard 02 Target 1    STANDARD FAM      NFQ-MGB     18.7  0.00751
#>  9 FALSE Standard 03 Target 1    STANDARD FAM      NFQ-MGB     22.3  0.0672 
#> 10 FALSE Standard 03 Target 1    STANDARD FAM      NFQ-MGB     22.3  0.0672 
#> # ... with 48 more rows, and 27 more variables: quantity_mean <dbl>,
#> #   quantity_sd <dbl>, automatic_ct_threshold <lgl>, ct_threshold <dbl>,
#> #   automatic_baseline <lgl>, baseline_start <dbl>, baseline_end <dbl>,
#> #   comments <chr>, y_intercept <dbl>, r2 <dbl>, slope <dbl>, efficiency <dbl>,
#> #   positions <dbl>, name <chr>, usr_quantity <dbl>, plate_type <chr>,
#> #   exp_type <chr>, well <chr>, well_position <chr>, ct <dbl>, quantity <dbl>,
#> #   well_row <dbl>, well_col <dbl>, standard_diff <dbl>, dil <dbl>, ...