Tensor Composition Analysis
Overview
Tensor Composition Analysis (TCA) allows the deconvolution of two-dimensional data (features by observations) coming from a mixture of heterogeneous sources into a three-dimensional matrix of signals (features by observations by sources). The TCA framework further allows to test the features in the data for different statistical relations with an outcome of interest while modeling source-specific effects; particularly, it allows to look for statistical relations between source-specific signals and an outcome. For example, TCA can deconvolve bulk tissue-level DNA methylation data (methylation sites by individuals) into a three-dimensional tensor of cell-type-specific methylation levels for each individual (i.e. methylation sites by individuals by cell types) and it allows to detect cell-type-specific statistical relations (associations) with phenotypes. For more details see Rahmani et al. (2019) DOI:10.1038/s41467-019-11052-9.
*NOTE* v1.2.1 is not backward compatible with earlier versions
Changes:
- A new argument 'vars.mle' in 'tca' which controls the method used for optimization; setting to FALSE allows a much faster optimization.
- A new argument 'fast_mode' in 'tcareg' allows a much faster optimization.
- A new argument 'constrain_mu' in 'tca' allows to determine whether to constrain the mean parameters in the optimization; setting to false now allows to obtain p-values for the covariates in 'C1' and 'C2'.
- A new 'scale' argument in 'tensor' for dividing estimates by estimated standard deviations.
- Default values of several arguments have been changed.
- Switched the default FDR method used in ‘tcareg’ back from “BY” to “BH” (can be changed by editing the config file).
From NEWS.md in the release
Install
Health
NOTERd filesr-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-x86_64, r-oldrel-macos-arm64, r-oldrel-macos-x86_64, r-oldrel-windows-x86_64, r-patched-linux-x86_64, r-release-linux-x86_64, r-release-macos-arm64, r-release-macos-x86_64, r-release-windows-x86_64
checkRd: (-1) tca.Rd:35: Lost braces; missing escapes or markup?
35 | \item{C1.map}{An \code{p1} by \code{k} matrix of 0/1 values, indicating for each of the \code{p1} covariates in \code{C1} whether to consider its potential effects on the values of each of the \code{k} sources (e.g., if position \code{i,j} in \code{C1.map} is 1 then the potential effect of the \code{i}-th covariate in \code{C1} on the {j}-th source will be considered). If \code{C1.map == NULL} then effects for all covariates in \code{C1} will be considered in each of the sources. Note that \code{C1.map} is available only if \code{constrain_mu == TRUE}.}
| ^NOTECRAN incoming feasibilityr-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc
Maintainer: ‘Elior Rahmani <elior.rahmani@gmail.com>’ Package CITATION file contains call(s) to old-style personList() or as.personList(). Please use c() on person objects instead. Package CITATION file contains call(s) to old-style citEntry(). Please use bibentry() instead.
NOTEdependencies in R coder-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc
Namespaces in Imports field not imported from: ‘Matrix’ ‘quadprog’ All declared Imports should be used.
- NOTE13 NOTE2026-09-08
- ERROR12 NOTE, 1 ERROR2026-09-07
- NOTE14 NOTE2026-03-10
Documentation
- Help pages
- 6
- Examples that run
- 100%6 run in a plain check
- Exported functions with examples
- 100%
- Documented parameters
- 100%
- Return-value docs
- 100%
- Help pages citing references
- 67%
Downloads
Repository
- PRs merged (all time)
- not measured
- Median days to close, 50 most recently updated closed issues
- 8
- Median days to close, 50 most recently updated closed PRs
- not measured
Stars over time
Forks over time
Releases over time
Issues over time
1 development-tooling and community-health practice detected across 1 family in the upstream repository
Checks run against github.com/cozygene/tca on 2026-10-11.
Dependencies
Installing TCA adds 17 packages (6 with compiled code, 13 MB of source tarballs). Heaviest: data.table 5.7 MB, rsvd 3.3 MB, nloptr 2.1 MB.
CRAN will archive these unless their check problems are fixed by the date shown. This package needs each one to install.
- lambda.r through futile.loggerdeadline passed Oct 12
Code & Tests
People & History
Pick two releases to compare their code metrics.
- RR 4.6.0 released · 2026-04-24
- RR 4.5.0 released · 2025-04-11
- RR 4.4.0 released · 2024-04-24
- RR 4.3.0 released · 2023-04-21
- RR 4.2.0 released · 2022-04-22
- RR 4.1.0 released · 2021-05-18
- 1.2.1Latest
- RR 4.0.0 released · 2020-04-24
- 1.1.02019-11-16 · diff ↗
- 1.0.02019-05-22
- RR 3.6.0 released · 2019-04-26
Package metadata
- First published
- 2019-05-22
- Total releases
- 3 / 7 yrs
- License
- GPL-3 OSI
- Minimum R
- ≥ 3.5.0
- Download size
- 1.0 MB
Cite
Cite this package
Run in R for the authors' entry:
citation("TCA")The package provides a citation file, so citation() returns the authors' own entry.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-19, which the citation names so these numbers can be found later. More on citing and the projects behind them.