Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

highlight cells in FeaturePlot with expression of two or more genes #1343

Closed
rahulnutron opened this issue Apr 9, 2019 · 6 comments
Closed

Comments

@rahulnutron
Copy link

I am trying to identify cells which simultaneously express (if any) two or more genes of my choice. The expression may depend on a cut-off value. This can help me to identify a cell type. However, in feature plot I can see cells/cluster for only one gene. Is it possible to obtain such cell's information and marker genes only for these cells?

@mojaveazure
Copy link
Member

Hi Rahul,

You can visualize the co-expression of two features by passing blend = TRUE; this will generate four plots: expression of the first feature, expression of the second, expression of the two together, and a heatmap key

FeaturePlot(object = pbmc_small, features = c('MS4A1', 'CD79B'), blend = TRUE)

image

@fly4all
Copy link

fly4all commented Apr 10, 2019

Hi. Following up on the same question, is there a way to see expression of more than 2 genes together?

@rahulnutron
Copy link
Author

Thanks Paul! I need to update Seurat as I got an error
unused argument (blend = TRUE)

@rahulnutron
Copy link
Author

This is useful. However, I want to do something different. I have 6 clusters. One of these clusters has 3-4 cells of rare cell-type. I can see that when I used FeaturePlot for three genes. All three genes has expression in some particular cells (however expression varies). I want to highlight the same cells for these three genes in the same plot (i.e., all cells having these three genes expressed simultaneously should be highlighted). The lower expression can be determined by some cut-off value. Then I want to perform DE analysis with these cells vs all others to find markers of this rare cell-type.

Thanks for help!

I have a code but its the same pipeline as given in the website. I just cant go beyond the FeaturePlot.

@mojaveazure
Copy link
Member

Hi Maria and Rahul,

Currently, Seurat does not offer a way to visualize coexpression of more than two features. If you want to select cells based on expression of features, you can use WhichCells and pass the expression cutoffs the same way you would when subsetting a data frame (no quotes, backticks when calling features that have dashes in their names)

> # An example using the PBMC 3k object from our PBMC 3k tutorial
> WhichCells(object = pbmc_small, expression = MS4A1 > 3 & CD79A > 3 & CD3E > 3)
[1] "TTGGTACTGAATCC" "CATCATACGGAGCA" "TACATCACGCTAAC"

You could then take these cells, change the identity of them (see ?Idents for more details), and use that for differential expression.

@Yale73
Copy link

Yale73 commented Nov 14, 2019

@mojaveazure Hi mojaveazure, I found we have the "overlay" parameter in FeaturePlot for Seurat v2.3.4, which can put two genes together in one featureplot, is it possible to recover this function, or do we upgrade this parameter to "blend"?

Thanks,
Yale

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants