[](https://pypi.org/project/fba/)
[](https://bioconda.github.io/recipes/fba/README.html)
[](https://github.com/jlduan/fba/blob/master/LICENSE)
[](https://github.com/jlduan/fba/actions/workflows/ci.yml)
[](https://app.circleci.com/pipelines/github/jlduan/fba)
[](https://fba.readthedocs.io/en/latest/index.html)
[](https://app.codecov.io/gh/jlduan/fba)
[](https://github.com/jlduan/fba/commits)
[](https://doi.org/10.5281/zenodo.4642814)
<br>
<a href="https://jlduan.github.io/fba">
<img src="https://raw.githubusercontent.com/jlduan/fba/gh-pages/docs/_static/logo.svg" align="right" width='200'/>
</a>
> **工欲善其事,必先利其器。—— 论语·卫灵公**
# `fba`
Tools for single-cell feature barcoding analysis
> Jialei Duan, Gary C Hon, **FBA: feature barcoding analysis for single cell RNA-Seq**, _Bioinformatics_, Volume 37, Issue 22, 15 November 2021, Pages 4266–4268. DOI: <https://doi.org/10.1093/bioinformatics/btab375>. PMID: [33999185](https://pubmed.ncbi.nlm.nih.gov/33999185/).
<br>
## What is `fba`?
`fba` is a flexible and streamlined toolbox for quality control, quantification, demultiplexing of various feature barcoding assays. It can be applied to customized feature barcoding specifications, including different CRISPR constructs or targeted enriched transcripts. `fba` allows users to customize a wide range of parameters for the quantification and demultiplexing process. `fba` also has a user-friendly quality control module, which is helpful in troubleshooting feature barcoding experiments.
<br>
## Installation
`fba` can be installed with `pip`:
```shell
pip install fba
```
Alternatively, you can install this package with `conda`:
```shell
conda install -c bioconda fba
```
<br>
## Workflow Example
- CRISPR screening
- [10k A375 Cells Transduced with (1) Non-Target and (1) Target sgRNA, Dual Indexed](https://jlduan.github.io/fba/_build/html/tutorials/crispr_screening/SC3_v3_NextGem_DI_CRISPR_10K/tutorial.html)
- [CROP-seq; 1:1:1 Mixture of DNMT3B, MBD1, and TET2 Knockout Cell Lines (HEK293T)](https://jlduan.github.io/fba/_build/html/tutorials/crispr_screening/PRJNA358686/tutorial.html)
- [Direct-capture Perturb-seq; CRISPRi-based Screen of Unfolded Protein Response (UPR) Using 3' sgRNA-CR1<sup>cs1</sup>](https://jlduan.github.io/fba/_build/html/tutorials/crispr_screening/PRJNA609688/tutorial.html)
- Cell surface protein labeling
- [CITE-seq; 8k Cord Blood Mononuclear Cells with 13 Antibodies](https://jlduan.github.io/fba/_build/html/tutorials/cell_surface_protein_labeling/PRJNA393315/tutorial.html)
- [ASAP-seq; Multiplexed CRISPR Perturbations in Primary T Cells](https://jlduan.github.io/fba/_build/html/tutorials/cell_surface_protein_labeling/PRJNA658075/tutorial.html)
- [1k Human PBMCs Stained with a Panel of TotalSeq B Antibodies, Dual Indexed](https://jlduan.github.io/fba/_build/html/tutorials/cell_surface_protein_labeling/SC3_v3_NextGem_DI_PBMC_CSP_1K/tutorial.html)
- ECCITE-seq
- [6k Single-cell Multimodal Readout of NIH-3T3, MyLa, Sez4 and PBMCs](https://jlduan.github.io/fba/_build/html/tutorials/eccite-seq/PRJNA521522/tutorial.html)
- PHAGE-ATAC
- [Anti-CD8 Phage Hashing Single-cell ATAC-seq Using CD8 T Cells from Four Human Donors](https://jlduan.github.io/fba/_build/html/tutorials/phage-atac/PRJNA661457/tutorial.html)
- CellPlex
- [10k 1:1 Mixture of Raji and Jurkat Cells Multiplexed, 2 CMOs](https://jlduan.github.io/fba/_build/html/tutorials/cellplex/SC3_v3_NextGem_DI_CellPlex_Jurkat_Raji_10K_Multiplex/tutorial.html)
- [30k Mouse E18 Combined Cortex, Hippocampus and Subventricular Zone Nuclei Multiplexed, 12 CMOs](https://jlduan.github.io/fba/_build/html/tutorials/cellplex/SC3_v3_NextGem_DI_CellPlex_Nuclei_30K_Multiplex/tutorial.html)
- Cell hashing
- [Peripheral Blood Mononuclear Cells with 8 Antibodies](https://jlduan.github.io/fba/_build/html/tutorials/cell_hashing/PRJNA423077/tutorial.html)
- MULTI-seq
- [15k HEK293 and 40k HMECs Multiplexed by Lipid- and Cholesterol-tagged Indices](https://jlduan.github.io/fba/_build/html/tutorials/multi-seq/PRJNA531855/tutorial.html)
- Targeted transcript enrichment
- [Hodgkin's Lymphoma, Dissociated Tumor: Targeted, Gene Signature Panel](https://jlduan.github.io/fba/_build/html/tutorials/targeted_transcript_enrichment/Targeted_NGSC3_DI_HodgkinsLymphoma_GeneSignature/tutorial.html)
- Pseudo-bulk
- [10k A375 Cells Transduced with (1) Non-Target and (1) Target sgRNA, Dual Indexed](https://jlduan.github.io/fba/_build/html/tutorials/pseudo-bulk/SC3_v3_NextGem_DI_CRISPR_10K/tutorial.html)
- [10k 1:1 Mixture of Raji and Jurkat Cells Multiplexed, 2 CMOs](https://jlduan.github.io/fba/_build/html/tutorials/pseudo-bulk/SC3_v3_NextGem_DI_CellPlex_Jurkat_Raji_10K_Multiplex/tutorial.html)
<br>
## Usage
```
$ fba
usage: fba [-h] ...
Tools for single-cell feature barcoding analysis
optional arguments:
-h, --help show this help message and exit
functions:
extract extract cell and feature barcodes
map map enriched transcripts
filter filter extracted barcodes
count count feature barcodes per cell
demultiplex demultiplex cells based on feature abundance
qc quality control of feature barcoding assay
kallisto_wrapper
deploy kallisto/bustools for feature barcoding
quantification
```
<br>
- **`extract`**: extract cell and feature barcodes from paired fastq files. For single cell assays, read 1 usually contains cell partitioning and UMI information, and read 2 contains feature information.
- **`map`**: quantify enriched transcripts (through hybridization or PCR amplification) from parent single cell libraries. Read 1 contains cell partitioning and UMI information, and read 2 contains transcribed regions of enriched/targeted transcripts of interest. BWA (Li, H. 2013) or Bowtie2 (Langmead, B., et al. 2012) is used for read 2 alignment. The quantification (UMI deduplication) of enriched/targeted transcripts is powered by UMI-tools (Smith, T., et al. 2017).
- **`filter`**: filter extracted cell and feature barcodes (output of `extract` or `qc`). Additional fragment filter/selection can be applied through `-cb_seq` and/or `-fb_seq`.
- **`count`**: count UMIs per feature per cell (UMI deduplication), powered by UMI-tools (Smith, T., et al. 2017). Take the output of `extract` or `filter` as input.
- **`demultiplex`**: demultiplex cells based on the abundance of features (matrix generated by `count` as input).
- **`qc`**: generate diagnostic information. If `-1` is omitted, bulk mode is enabled and only read 2 will be analyzed.
- **`kallisto_wrapper`**: deploy kallisto/bustools for feature barcoding quantification (just a wrapper) (Bray, N.L., et al. 2016).
<br>