Skip to content

Commit

Permalink
Add new lifting and bridging vignette
Browse files Browse the repository at this point in the history
- closes SomaLogic#77
  • Loading branch information
stufield committed Mar 5, 2024
1 parent d7401d1 commit 56e4d44
Show file tree
Hide file tree
Showing 6 changed files with 303 additions and 32 deletions.
2 changes: 1 addition & 1 deletion R/adat-helpers.R
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#' [checkSomaScanVersion()] determines if the version of
#' is a recognized version of SomaScan.\cr
#' \cr
#' Table of SomaScan Assay versions:
#' Table of SomaScan assay versions:
#' \tabular{lll}{
#' **Version** \tab **Commercial Name** \tab **Size** \cr
#' `V4` \tab 5k \tab 5284 \cr
Expand Down
18 changes: 5 additions & 13 deletions R/lift-adat.R
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#' between assay versions; from changing reagents, liquid handling equipment,
#' well volumes, and content expansion.
#'
#' Table of SomaScan Assay versions:
#' Table of SomaScan assay versions:
#'
#' \tabular{lll}{
#' **Version** \tab **Commercial Name** \tab **Size** \cr
Expand Down Expand Up @@ -36,11 +36,10 @@
#' @details
#' Matched samples across assay versions are used to calculate bridging
#' scalars. For each analyte, this scalar is computed as the ratio of
#' population _medians_ (\eqn{n > 1000}) between assay versions. For example,
#' the linear scalar for the \eqn{i^{th}} analyte translating from `11k` -> `7k`
#' is defined as:
#'
#' \deqn{R_i = \frac{\hat\mu_{7k}}{\hat\mu_{11k}}}
#' population _medians_ across assay versions.
#' Please see the lifting vignette
#' `vignette("lifting-and-bridging", package = "SomaDataIO")`
#' for more details.
#'
#' @section Lin's CCC:
#' Calculating analyte-specific bridging scalars involves a careful evaluation
Expand All @@ -57,13 +56,6 @@
#' you may view the analyte-specific CCC values via [read_annotations()].
#' Alternatively, [getSomaScanLiftCCC()] retrieves these values
#' from an internal object for both `"serum"` and `"plasma"`.
#' Lin's CCC (\eqn{p_c}) is defined by:
#'
#' \deqn{p_c = \frac{2\rho\hat\sigma_x\hat\sigma_y}{(\hat\mu_x - \hat\mu_y)^2 + \hat\sigma^2_x + \hat\sigma^2_y}}
#'
#' where \eqn{\rho}, \eqn{\mu}, and \eqn{\sigma} are the Pearson correlation
#' coefficient, and estimated median and standard deviation estimates from
#' assay version groups \eqn{x} and \eqn{y} respectively.
#'
#' @section Extra Columns:
#' * Newer versions of SomaScan typically have additional content, i.e.
Expand Down
16 changes: 12 additions & 4 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ navbar:
href: articles/stat-binary-classification.html
- text: Linear Regression
href: articles/stat-linear-regression.html

FAQs:
text: Coming Soon
menu:
Expand All @@ -106,6 +106,11 @@ articles:
contents:
- cli-merge-tool

- title: Lifting and Bridging
navbar: ~
contents:
- lifting-and-bridging

- title: Statistical Workflow Examples
contents:
- starts_with("articles/stat-")
Expand Down Expand Up @@ -139,12 +144,15 @@ reference:

- title: Transform Between SomaScan Versions
desc: >
Functionality required to convert between SomaScan versions,
e.g. v4.1 -> v4.0, sometimes referred to as "lifting".
Functionality required to bridge between SomaScan versions,
e.g. 11k -> 7k, sometimes referred to as "lifting".
contents:
- read_annotations
- lift_adat
- read_annotations
- transform
- getSomaScanLiftCCC
- getSomaScanVersion
- getSignalSpace

- title: Expression Data
desc: >
Expand Down
2 changes: 1 addition & 1 deletion man/adat-helpers.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 5 additions & 13 deletions man/lift_adat.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 56e4d44

Please sign in to comment.