# Third-party CRISPR Guide Assignment Toolkit

[Crispat](https://academic.oup.com/bioinformatics/article/40/9/btae535/7750392) is a peer-reviewed CRISPR guide calling package that conveniently bundles many popular gRNA thresholding approaches, enabling users to compare the performance of multiple approaches side-by-side.&#x20;

Here, we implement one of these approaches, the Gaussian-Gaussian Mixture Model, which we've found performs best with the Illumina's Single-Cell CRISPR Prep kit.&#x20;

[Instructions for how to download and install](https://github.com/aamayzhang/crispat_iscp/tree/main) our optimized fork of crispat can be found[ here](https://github.com/aamayzhang/crispat_iscp/tree/main).

In brief, the model does the following:

* Read in DRAGEN filtered matrix files from an DRAGEN output directory.
* Creates and reads in a .h5ad file (via scanpy).
* Performs 2-component Gaussian-Gaussian mixture modeling on the gRNA counts.
* Outputs gRNA assignments for each cell barcode along with plots showing the fit of the model to the raw counts.

A [step-by-step tutorial](https://github.com/aamayzhang/crispat_iscp/blob/main/tutorial/iscp_demo.py) and a [small test dataset](https://github.com/aamayzhang/crispat_iscp/tree/main/example_data) can be found in the repo.

You should expect the plots of the models fit to nonzero count data to look similar to this:&#x20;

<figure><img src="/files/G5QOryG0K4du0jpWdl4N" alt=""><figcaption></figcaption></figure>

The output file *assignments.csv* provides a full list of all cell barcodes containing a guide that exceeded the threshold determined by the gaussian mixture model.  The outputs should look as follows:

<div align="left"><figure><img src="/files/dy17ZzePjecJ4XUwXk01" alt=""><figcaption></figcaption></figure></div>

`cell`:  the cell barcode sequence.

`gRNA` : the gRNA ID that was assigned to the cell.

`read_counts`:  the number of read counts observed for each cell-gRNA assignment.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.connected.illumina.com/dragen-single-cell-rna/tertiary-analysis/third-party-crispr-guide-assignment-toolkit.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
