Skip to contents

Read in and wrangle protein quantification data

Usage

qp_tidy(x, ...)

# S3 method for character
qp_tidy(x, ...)

# S3 method for spectramax
qp_tidy(
  x,
  replicate_orientation = c("h", "v"),
  n_standards = 7,
  n_replicates = 3,
  wavelength = 562,
  ...
)

# S3 method for gp
qp_tidy(x, ...)

# S3 method for default
qp_tidy(x, ...)

Arguments

x

A gp, data.frame/tibble, spectramax, or character path to a raw SPECTRAmax .xls(x)/.txt

...

Arguments passed to relevant methods.

replicate_orientation

Character. Specified the direction the replicates lie, not the direction the samples flow (which will be perpendicular to replicate_orientation).

n_standards

Numeric. The number of different concentrations of standards. Does not include replicates.

n_replicates

Numeric. The number of replicates per sample.

wavelength

Numeric. For SPECTRAmax files and objects, the wavelength measured. Otherwise, ignored.

Value

a data.frame

Details

qp assumes that if you read in data not in a spectramax file or object, you probably have a custom workflow in mind - therefore, tidying will be minimal and mostly focused on checking for validity.

Examples


data <- system.file("extdata", "absorbances.txt", package = "qp")
qp_tidy(data)
#> Please wait. This will take ~10 seconds.
#> # A tibble: 96 × 5
#>     .row  .col   .abs sample_type index
#>    <int> <dbl>  <dbl> <fct>       <dbl>
#>  1     1     1 0.0686 standard        1
#>  2     1     2 0.0717 standard        1
#>  3     1     3 0.0698 standard        1
#>  4     2     1 0.0825 standard        2
#>  5     2     2 0.0832 standard        2
#>  6     2     3 0.0835 standard        2
#>  7     3     1 0.102  standard        3
#>  8     3     2 0.100  standard        3
#>  9     3     3 0.102  standard        3
#> 10     4     1 0.132  standard        4
#> # ℹ 86 more rows