Package 'saintexpress'

Title: Pure R Implementation of SAINTexpress
Description: A pure R implementation of the SAINTexpress scoring engines for affinity purification-mass spectrometry data, covering both the spectral-count and intensity models, together with validation of SAINT input tables. The output mirrors the native SAINTexpress 'list.txt' format, so protein-protein interactions can be scored without external binaries. The underlying method is described in Teo et al. (2014) <doi:10.1016/j.jprot.2013.10.023>.
Authors: Witold Wolski [cre] (ORCID: <https://orcid.org/0000-0002-6468-120X>), Alexey Nesvizhskii [aut], Hyungwon Choi [aut, cph] (Author and copyright holder of the original SAINTexpress C++ implementation), Damian Fermin [aut, cph] (Author and copyright holder of the original SAINTexpress C++ implementation)
Maintainer: Witold Wolski <[email protected]>
License: GPL (>= 3)
Version: 0.99.0
Built: 2026-09-26 09:52:06 UTC
Source: https://github.com/BiocStaging/saintexpress

Help Index


Run the pure-R SAINTexpress engine

Description

Dispatches to the spectral-count or intensity scorer.

Usage

run_saint(si, mode = c("spc", "int"), optimizer = c("base", "nloptr"), ...)

Arguments

si

A named list with elements inter, prey, bait (data frames).

mode

"spc" for spectral counts, "int" for intensities.

optimizer

"base" (default; uses stats::optim()) or "nloptr" (uses NLopt COBYLA via the optional nloptr package).

...

Additional arguments forwarded to the internal scorers saint_spc_r() or saint_int_r() (e.g. R, L, frequency, p2p_mapping).

Value

A data frame in the SAINTexpress list.txt shape.

Examples

si <- list(
  inter = data.frame(
    ipId = c("IP1", "IP1", "IP2", "IP2", "IP3", "IP4"),
    baitId = c("BaitA", "BaitA", "BaitA", "BaitA", "Ctrl", "Ctrl"),
    preyId = c("Prey1", "Prey2", "Prey1", "Prey2", "Prey1", "Prey2"),
    quant = c(20, 1, 18, 1, 1, 1)
  ),
  prey = data.frame(
    preyId = c("Prey1", "Prey2"),
    preyLength = c(500, 500),
    preyGeneId = c("Gene1", "Gene2")
  ),
  bait = data.frame(
    ipId = c("IP1", "IP2", "IP3", "IP4"),
    baitId = c("BaitA", "BaitA", "Ctrl", "Ctrl"),
    CorT = c("T", "T", "C", "C")
  )
)
run_saint(si, mode = "spc")

Validate a SAINT input list

Description

Checks that si is a list with exactly the elements inter, prey, bait, and that each is a data frame.

Usage

validate_saint_input(si)

Arguments

si

A named list with elements inter, prey, bait.

Value

TRUE invisibly on success; otherwise stops with a message.

Examples

si <- list(
  inter = data.frame(ipId = "IP1", baitId = "BaitA", preyId = "Prey1"),
  prey = data.frame(preyId = "Prey1"),
  bait = data.frame(ipId = "IP1", baitId = "BaitA", CorT = "T")
)
validate_saint_input(si)