Welcome to Barnacle’s documentation!

Barnacle is a Python package for fitting sparse tensor decomposition models. These models are useful tools for analyzing multi-way datasets, in which a response variable has been measured in regards to three or more modes of variation. Barnacle was originally developed for the purpose of analysing metatranscriptomic datasets [1], but could feasibly be applied to any multi-way dataset. To jump right into using Barnacle, see the installation instructions and peruse the example gallery. Go to the model description page to learn more about Barnacle’s implementation of a sparse tensor decomposition model, as well as more information about tensor decomposition models in general. To learn more about applying Barnacle to metatranscriptomics and other omics datatest, navigate to the omics page. For detailed discussion of these topics and more, check out our 2025 publication in Science Advances [1] as well as the Barnacle GitHub repository

This project is dependent on, and we are grateful for the work of many open source projects. In particular, we rely on the Python package Tensorly [2] for most foundational tensor manipulations. The Tensorly website is an excellent resource for tools and information on working with tensors, including tensor decompositions.

Illustration of barnacles, coral, a starfish, a seashell, and bubbles.

Illustration by Robin Aguilar.

Contents

Indices and tables