# Differentially Expressed Proteins and Genes

* [Filter Groups](#filter-groups)
* [Re-split the Matrix](#re-split-the-matrix)
* [Differential Analysis and Visualization - Protein Data](#differential-analysis-and-visualization---protein-data)
* [Differential Analysis, Visualization, and Pathway analysis - Gene Expression Data](#differential-analysis-visualization-and-pathway-analysis---gene-expression-data)

Next, we will filter out certain cells and re-split the data. Re-splitting the data can be useful if you want to perform differential analysis and downstream analysis separately for proteins and genes. For your own analyses, re-splitting the data is optional. You could just as well continue with differential analysis with the merged data if you prefer.

## Filter Groups

Because we have classified our cells, we can now filter based on those classifications. This can be used to focus on a single cell type for re-clustering and sub-classification or to exclude cells that are not of interest for downstream analysis.

* Click the **Merged counts** data node
* Click **Filtering**
* Click **Filter cells**
* Set to **exclude** **Cell type is Doublets** using the drop-down menus
* Click **OR**
* Set the second filter to **exclude Cell type is N/A** using the drop-down menus
* Click **Finish** to apply the filter (Figure 1)

![Figure 1. Set up the Filter groups task to exlcude Doublets and cells that are not classified](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-5d8dcb7f77d6f7344b8dda9ad6042a2f0caacf98%2FScreenshot%202023-09-21%20at%2017.59.17.png?alt=media)

This produces a *Filtered counts* data node (Figure 2).

![Figure 2. Filter groups output](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-84f130ed5a1d4c2ebc6d4a961ac8fe5e9d5d3d03%2FScreenshot%202023-09-21%20at%2018.00.32.png?alt=media)

## Re-split the Matrix

* Click the **Filtered counts** data node
* Click **Pre-analysis tools**
* Click **Split by feature type**

This will produce two data nodes, one for each data type (Figure 3). The split data nodes will both retain cell classification information.

![Figure 3. It is possible to re-split the merged matrix once again](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-ba9104698de7414c5e8be632e68d50ffd1799ffd%2FScreenshot%202023-09-22%20at%2016.16.58.png?alt=media)

## Differential Analysis and Visualization - Protein Data

Once we have classified our cells, we can use this information to perform comparisons between cell types or between experimental groups for a cell type. In this project, we only have a single sample, so we will compare cell types.

* Click the **Antibody Capture** data node
* Click **Statistics**
* Click **Differential analysis**
* Click **ANOVA** then click **Next**

The first step is to choose which attributes we want to consider in the statistical test.

* Click **Cell type**
* Click **Add factor**
* Click **Next**

Next, we will set up the comparison we want to make. Here, we will compare the Activated and Mature B cells.

* Drag **Activated B cells** in the top panel
* Drag **Mature B cells** in the bottom panel
* Click **Add comparison**

The comparison should appear in the table as *Activated B cells vs. Mature B cells*.

* Click **Finish** to run the statistical test (Figure 4)

![Figure 4. Setting up a comparison for differentially expressed proteins](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-cb20f9d812b0a9c821b415d7f5933c4a55897ac5%2FScreenshot%202023-09-22%20at%2016.15.19.png?alt=media)

The *ANOVA* task produces an *ANOVA* data node.

* Double-click the **ANOVA** data node to open the task report

The report lists each feature tested, giving p-value, false discovery rate adjusted p-value (FDR step up), and fold change values for each comparison (Figure 5).

![Figure 5. GSA report for protein expression data](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-cd1474c6513ea874216a9dee3d97aab150408154%2FScreenshot%202023-09-22%20at%2016.23.22.png?alt=media)

In addition to the listed information, we can access dot and violin plots for each gene or protein from this table.

* Click ![image2019-5-24 14\_50\_50](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-233ea4641f896a016fd835fa11a3d7528c94930b%2Fscatter-plot-icon.png?alt=media) in the *CD45RA\_TotalSeqB* row

This opens a dot plot in a new data viewer session, showing CD45A expression for cells in each of the classifications (Figure 6). First, we exclude *Doublets* and *N/A* cells from the plot:

* Open **Select and filter**, select **Criteria**
* Drag "Cell type" from the legend title to the **Add criteria** box
* Uncheck **Doublets** and **N/A**
* Click to include selected points

![Figure 6. CD45RA dot plot for all cells](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-d0e5bd55f02f240c00d746dee13ec161cae118e1%2FScreenshot%202023-09-22%20at%2016.30.43.png?alt=media)

We can use the *Configuration* panel on the left to edit this plot.

* Open the **Style** icon
* Switch on **Violins** under *Summary*
* Switch on **Overlay** under *Summary*
* Switch on **Colored** under *Summary*
* Select the *Graph-based clustering* node in the **Color by** section
* **Color by** Graph-based clusters under **Color** and use the slider to decrease the **Opacity**
* Open the **Axes** icon
* Select the *Graph-based clustering* node in the **X axis** section
* Change the *X axis data* to Graph-based clusters
* Use the slider to increase the **Jitter** on the *X axis* (Figure 7)

![Figure 7. Configure the dot plot using the tools on the left](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-e6a2882b9ba0051c750d87de3db18fdefe73fa09%2FScreenshot%202023-09-22%20at%2016.35.47.png?alt=media)

* Click the **project name** to return to the *Analyses* tab

To visualize all of the proteins at the same time, we can make a hierarchical clustering heat map.

* Click the **ANOVA** data node
* Click **Exploratory analysis** in the toolbox
* Click **Hierarchical clustering/heatmap**
* In the *Cell order* section, choose **Graph-based clusters** from the *Assign order* drop-down list
* Click **Finish** to run with the other default settings
* Double-click the **Hierarchical clustering** task node to open the heatmap

The heatmap can easily be customized using the tools on the left.

* Open the **Axes** icon
* Switch off *Show* **Row labels**
* Increase the **Font** to 16 (Figure 8)

![Figure 8. Heatmap showing altered Axes labels](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-ba31427ad6f48018d2e121bbac33fc463bbbf239%2FScreenshot%202023-09-25%20at%2009.53.25.png?alt=media)

* Activate the **Transpose** switch which will switch the Row and Column labels, so now the Row labels will be shown (Figure 9)

![Figure 9. Transpose the Heatmap to switch the columns and rows](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-cfa9098093cfb284b6e514a022d0b6b9d1d95b14%2FScreenshot%202023-09-25%20at%2009.53.43.png?alt=media)

* Open the **Dendrograms** icon
* Choose *Row color* **By cluster** and change *Row clusters* to **4**
* Change *Row dendrogram size* to **80** (Figure 10)

![Figure 10. Configure the Dendrograms settings](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-16ad92d5a5e801c68658019b6def5256e22841bb%2FScreenshot%202023-09-25%20at%2009.55.08.png?alt=media)

* In the **Heatmap** icon
* Navigate to *Range* under *Color*
* Set the Min and Max to **-1.2** and **1.2**, respectively
* Change the *Shape* to **Circle** (Figure 11)

![Figure 11. Configure the Heatmap icon](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-f69dbc26acbbbb83fa048c5314f261e0274e5bbd%2FScreenshot%202023-09-25%20at%2009.56.00.png?alt=media)

* Switch the *Shape* back to **Rectangle**
* Change the *Color Palette* by clicking on the color squares and selecting colors from the rainbow. Click outside of the selection box to exit this selection. The color options can be dragged alone the Palette to highlight value differences (Figure 12).

![Figure 12. Heatmap showing expression of protein markers after changing the Heatmap settings further](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-61fda64cfd88939f67663c0cb18d91392599192b%2FScreenshot%202023-09-25%20at%2009.56.55.png?alt=media)

Feel free to explore the other tool options on the left to customize the plot further.

## Differential Analysis, Visualization, and Pathway analysis - Gene Expression Data

We can use a similar approach to analyze the gene expression data.

* Click the **project name** to return to the *Analyses* tab
* Click the **Gene Expression** data node
* Click the **Antibody Capture** data node
* Click **Statistics**
* Click **Differential analysis**
* Click **ANOVA** then click **Next**
* Click **Cell type**
* Click **Add factor**
* Click **Next**
* Drag **Activated B cells** in the top panel
* Drag **Mature B cells** in the bottom panel
* Click **Add comparison**

The comparison should appear in the table as *Activated B cells vs. Mature B cells*.

* Click **Finish** to run the statistical test

As before, this will generate an *ANOVA* task node and n *ANOVA* data node.

* Double-click the **ANOVA** task node to open the task report (Figure 13)

![Figure 13. GSA report for the gene expression data](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-47c8125b7a684624bb44274252704fffbd986988%2FScreenshot%202023-09-25%20at%2009.58.31.png?alt=media)

Because more than 20,000 genes have been analyzed, it is useful to use a volcano plot to get an idea about the overall changes.

* Click ![image2019-5-24 15\_5\_13](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-0356976f14f78eaf8131d71634d7494c100b8750%2Fvolcano-icon.png?alt=media) in the top right corner of the table to open a volcano plot

The Volcano plot opens in a new data viewer session, in a new tab in the web browser. It shows each gene as a point with cutoff lines set for P-value (y-axis) and fold-change (x-axis). By default, the P-value cutoff is set to 0.05 and the fold-change cutoff is set at |2| (Figure 14).

The plot can be configured using various tools on the left. For example, the **Style** icon can be used to change the appearance of the points. The X and Y-axes can be changed in the **Axes** icon. The **Statistics** icon can be used to set different Fold-change and P-value thresholds for coloring up/down-regulated genes. The in plot controls can be used to transpose ![image2022-8-30\_9-58-46](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-5ca6e1a5bcc3c17027287c2d89185844b2eb3b74%2Ftranspose-button.png?alt=media) the volcano plot (Figure 14).

![Figure 14. The volcano plot can be Configured using the icons on the left and in plot controls](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-76f41d01e01dcac7dba0dd3a31336dc29dd37442%2FScreenshot%202023-09-25%20at%2010.00.05.png?alt=media)

* Click the **ANOVA report** tab in your web browser to return to the full report

We can filter the full set of genes to include only the significantly different genes using the filter panel on the left.

* Click **FDR step up**
* Type **0.05** for the cutoff and press **Enter** on your keyboard
* Click **Fold change**
* Set to From **-2** to **2** and press **Enter** on your keyboard

The number at the top of the filter will update to show the number of included genes (Figure 15).

![Figure 15. Use the panel on the left to filter the list for significant genes](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-253a617792144cd79e9e9eb242eed50ca92f957a%2FScreenshot%202023-09-25%20at%2010.01.32.png?alt=media)

* Click ![Screenshot 2023-09-25 at 10 01 54](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-acceb8100101d58669312409e9c165daea86e48b%2Fgenerate-filtered-node-button.png?alt=media) to create a new data node including only these significantly different genes

A task, *Differential analysis filter*, will run and generate a new *Filtered* *Feature list* data node. We can get a better idea about the biology underlying these gene expression changes using gene set or pathway enrichment. Note, you need to have the Pathway toolkit enabled to perform the next steps.

* Click the **Filtered feature list** data node
* Click **Biological interpretation** in the toolbox
* Click **Pathway enrichment**
* Make sure that **Homo sapiens** is selected in the *Species* drop-down menu
* Click **Finish** to run
* Double-click the **Pathway enrichment** task node to open the task report

The pathway enrichment results list KEGG pathways, giving an enrichment score and p-value for each (Figure 16).

![Figure 16. Results of pathway enrichment test](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-0cd8f2456808a47b976d1301f51f7a098b260624%2FScreenshot%202023-09-25%20at%2010.09.13.png?alt=media)

To get a better idea about the changes in each enriched pathway, we can view an interactive KEGG pathway map.

* Click **path:hsa05202** in the Transcriptional misregulation in cancer row

The KEGG pathway map shows up-regulated genes from the input list in red and down-regulated genes from the input list in green (Figure 17).

![Figure 17. Transcriptional misregulation in cancer pathway with significant genes highlighted in green and red](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-054b1bcce01a15c304c6cff68461c79bcbee7a0a%2FScreenshot%202023-09-25%20at%2010.09.30.png?alt=media)

![Figure 18. Final CITE-Seq pipeline](https://1384254481-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJVEESmJAPppJ3ijFq5aR%2Fuploads%2Fgit-blob-895adad6118e0aba60816730ee43b09f712dbe74%2FScreenshot%202023-09-25%20at%2010.10.06.png?alt=media)

## Additional Assistance

If you need additional assistance, please visit [our support page](http://www.partek.com/support) to submit a help ticket or find phone numbers for regional support.
