Partek Flow Documentation

Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

t-SNE is a visualization method commonly used analyze single-cell RNA-Seq data. Each cell is shown as a point on the plot and each cell is positioned so that it is close to cells with similar overall gene expression. When working with multiple samples, a t-SNE plot can be drawn for each sample or all samples can be combined into a single plot. Viewing samples individually is the default in Partek Flow because sample to sample variation and outlier samples can obscure cell type differences if all samples are plotted together. However, as you will see in this tutorial, in some data sets, cell type differences can be visualized even when samples are combined.

Using the t-SNE plot, cells can be classified based on clustering results or differences in gene and pathway expression. 

Classifying cells using the interactive t-SNE plot

By default, each sample in a multi-sample data set is plotted on its own t-SNE. 

  • Select the Single cell data node
  • Select t-SNE from the Visualizations section of the task menu (Figure 1)

Figure 1. Invoking t-SNE from the task menu
  • Select Finish from the t-SNE dialog to run t-SNE with the default settings

A t-SNE task node will be generated (Figure 2).

 

Figure 2. t-SNE task node

Once the t-SNE task has completed, we can view the t-SNE plot.

  • Select the t-SNE task node
  • Select Task report from the task menu (Figure 3)

 

Figure 3. Opening the t-SNE plot

The t-SNE plot will open to the first sample in the data set, Astrocytoma 1 (Figure 4). Please note that the appearance of the t-SNE plot will differ each time it is drawn so your t-SNE plots will look different than those shown in this tutorial; however, the cell-to-cell relationships indicated will be the same. 

 

Figure 4. Viewing t-SNE plot of Astrocytoma 1

The t-SNE plot is in 3D by default. You can rotate the 3D plot by lef-clicking and dragging your mouse. You can zoom in and out using your mouse wheel. The 2D t-SNE is also calculated and you can switch between the 2D and 3D plots using the Plot style radio buttons. 

Each sample has its own plot. We can switch between samples using the Back and Next buttons on the upper left. 

  • Select Next

The t-SNE plot has switched to show the next sample, Astrocytoma 2 (Figure 5). 

 

Figure 5. Viewing t-SNE plot of Astrocytoma 2

The goal of this experiment is to compare malignant cells from two different glioma subtypes, astrocytoma and oligodendroglioma. To do this, we need to identify which cells are the malignant cells we want to include and which cell are the normal cells we want to exclude. 

The t-SNE plot in Partek Flow offers several options for identifying, selecting, and classifying cells. In this tutorial, we will use expression of known marker genes to identify normal cells. 

To visualize expression of a marker gene, we can color cells on the t-SNE plot by their expression level. 

  • Open the Color by drop-down menu
  • Select Gene expression from the drop-down menu (Figure 6)

Figure 6. Selecting color by gene expression

The cells will turn black and a text box Gene ID will open below the drop-down box. 

  • Type CD14 in the Gene ID text box
  • Select CD14 from the list of genes in the data set (Figure 7)

Figure 7. Coloring cells by CD14 expression

The cells will be colored from black to green based on their expression level of CD14, with cells expressing higher levels more green (Figure 8). CD14 is a known marker for microglia and macrophage cells, used by the authors of the original study to classify microglia/macrophage cells. 

 

Figure 8. Cells colored by CD14 expression

In Partek Flow, we can color cells with up to three genes at a time. We will now add a second gene, MOBP. 

  • Select the  icon next to CD14
  • Type MOBP in the new Gene ID box
  • Select MOBP from the list of genes in the data set

Cells expressing MOBP are now colored red and cells expressing CD14 are colored green. Cells expressing both genes are colored yellow, while cells expressing neither are colored black (Figure 9).

 

Figure 9. Coloring cells by MOBP and CD14

Relative expression of the two genes for selected cells can be visualized on the legend. 

  • Activate the 3D lasso tool by selecting  
  • Draw a circle around the cluster of red cells (Figure 10)

Figure 10. Selecting a group of cells using the 3D lasso tool

Selected cells are shown in bold and unselected cells are dimmed.

The relative expression of the two genes for the selected cells will be shown on the legend as dots (Figure 11). 

 

Figure 11. Viewing expression levels for a group of cells

Numerical expression levels for each gene can be viewed for individual cells. 

  • Switch modes by selecting 
  • Select a cell by pointing and clicking

The expression level for that cell is displayed on the legend for each gene (Figure 12). 

  • Deselect the cell by clicking on any black space on the plot

Expression values can also be viewing by selecting Gene Expression from the Label by drop-down menu and mousing over a cell. 

 

Figure 12. Viewing expression levels for an individual cell. The dots on the legend indicate the expression level of the selected cell.

Now that cells are colored by expression of a microglia/macrophage marker, CD14, and a oligodendrocyte marker, MOBP, we can classify any cell that does not fall into one of these two groups as malignant cells. Because t-SNE groups cells that are similar across the high-dimensional gene expression data, we will consider cells that form a group with CD14 or MOBP-expressing cells as same cell type, even if they do not express the marker gene.

Starting with the Astrocytoma 2 sample, we can classify the malignant cells in each sample. 

  • Activate the 3D lasso tool by selecting 
  • Draw the lasso around the cluster of black cells and click the circle to close the lasso (Figure 13). You may need to switch to selection mode and rotate the 3D plot to select only cells from the black cluster

Figure 13. Selecting malignant cells
  • Select Classify selection (Figure 14)

Figure 14. Classifying selected cells
A dialog to give the classification a name will appear. 

  • Name the classification Malignant 
  • Select Save (Figure 15)

Figure 15. Classifying selection

Once cells have been classified, the classification is added to the Classifications section of the panel. The number of cells belonging to the classiciation is listed; in Astrocytoma 2, there are 253 malignant cells (Figure 15). 

 

Figure 16. The number of cells in each classification is displayed in the classification section.
Classifications made on the t-SNE plot are retained as a draft until you exit the t-SNE task report. The Save classifications button runs a task, Classify cells, which generates a new Classified cells data node. In this tutorial, we will classify malignant cells for each sample before we save the classifications, but if necissary, you can run Classify cells for one sample, exit the t-SNE task report, and continue classifying the next sample later starting with the Classified cells data node. 

  • Select Next to move to the next sample, Astrocytoma 3
  • Rotate the 3D t-SNE plot to allow you to select only cells from the black cluster
  • Activate the 3D lasso tool by selecting 
  • Draw the lasso around the cluster of black cells and click the circle to close the lasso (Figure 16). 

Figure 17. Classifying malignant cells
  • Select Classify selection 
  • Type Malignant or select Malignant from the prompt (Figure 17)
  • Select Save

Figure 18. Adding cells in a second sample to an existing classification
  • Repeat these steps for each of the 5 astrocytoma and 3 oligodendroglioma samples

Once all samples have been classified, it is useful to check the number of cells in each sample assigned to each classification. 

  • Select Classification summary (Figure 18)

Figure 19. Navigating to the classification summary

The classifications summary lists every sample, the number of cells in the sample, and the number of cells in each classification (Figure 19).

 

Figure 20. Viewing the classification summary

With the malignant cells in every sample classified, it is time to save the classifications.

  • Select Save classifications 
  • Select Save when asked to confirm

The pipeline view will open and the Classify cells tasks will run, generating a Classified groups data node (Figure 20).

 

Figure 21. The Classify cells tasks generates a Classified groups data node

Classifying cells from multiple samples using the interactive multi-sample t-SNE plot

For some data sets, cell types can be distinguished when all samples can be visualized together on one t-SNE plot. We will use a t-SNE plot of all samples to classify microglia/macrophage and oligodendrocyte cell types. 

  • Select the Single cell data data node
  • Select t-SNE from the Visualizations section of the task menu
  • Select Configure on the t-SNE dialog (Figure 21)

Figure 22. Accessing the t-SNE advanced options
  • Deselect the Split cells by sample option under Misc
  • Select Apply (Figure 22)

Figure 23. Setting t-SNE to plot all samples together
  •  Select Finish to run the t-SNE task

The t-SNE task will be added as a new green layer in the analysis tab (Figure 23).

 

 

Figure 24. All samples t-SNE task is added as a new layer

Once the task has completed, we can view the plot.

  • Select the green t-SNE plot task node
  • Select Task Report from the task menu

In the multi-sample t-SNE plot, each cell is initially colored by its sample (Figure 24).

 

Figure 25. Viewing the multi-sample t-SNE plot
  • Select 2D from the Plot style section

Viewing the 2D t-SNE plot, while most cells cluster by sample, there are a few clusters with cells from multiple samples (Figure 25).

 

Figure 26. Viewing the multi-sample t-SNE plot in 2D

Using the known maker genes, CD14 and MOBP, we can assess whether these multi-sample clusters belong to our known cell types. 

  • Select Gene expression from the Color by drop-down menu
  • Type CD14 in the new Gene ID box
  • Select CD14 from the list of genes in the data set
  • Select the  icon next to CD14
  • Type MOBP in the new Gene ID box
  • Select MOBP from the list of genes in the data set

After coloring by CD14, a microglia/macrophage marker, and MOBP, a oligodendrocyte maker, these two cell populations are clearly visible (Figure 26). 

 

Figure 27. Overlaying marker gene expression on the multi-sample t-SNE plot
  • Activate the 3D lasso tool by selecting 
  • Draw the lasso around the cluster of red cells and click the circle to close the lasso (Figure 27)

Figure 28. Classifying oligodendrocytes (red)
  • Select Save classifications

These red cells are MOBP positive, indicating that they are the oligodendrocytes from every sample. 

  • Name the classification Oligodendrocytes
  • Select Save

To clearly see the CD14 positive population, clear the current selection.

  • Switch modes by selecting 
  • Deselect by clicking on any black space on the plot

Green CD14 positive cells are the microglia/macrophages from every sample. 

  • Activate the 3D lasso tool by selecting 
  • Draw the lasso around the cluster of green cells and click the circle to close the lasso (Figure 28)

Figure 29. Classifying microglia/macrophages (green)
  • Select Save classifications
  • Name the classification Microglia
  • Select Save
  • Switch modes by selecting 
  • Deselect by clicking on any black space on the plot

Finally, we will classify all unclassified cells on the plot as the malignant cells from every sample.

  • Select Classifications from the Color by drop-down menu

Cells are now colored by classification, with Oligodendrocytes in blue, Microglia in red, and unclassified cells in grey.

  • Activate the 3D lasso tool by selecting 
  • Draw the lasso around the grey cells and click the circle to close the lasso (Figure 29)

Figure 30. Classifying malignant cells (grey)

  • Select Save classifications 
  • Name the classification Malignant
  • Select Save

With every cell from every sample classified, we can proceed to save classifications. 

  • Select Save classifications
  • Select Save when asked to confirm

The pipeline view will open and the Classify cells tasks will run, generating a new green-layer Classified groups data node (Figure 30). 

 

Figure 31. Classify cells tasks from multi-sample t-SNE plot


 

Additional Assistance

If you need additional assistance, please visit our support page to submit a help ticket or find phone numbers for regional support.

Your Rating: Results: 1 Star2 Star3 Star4 Star5 Star 1 rates

  • No labels