Comments (4)
Hey SimoniMD,
This is a good suggestion and actually the way I generally summarise my enrichment results - I will add it to the to do list and have it released in the next version.
In the interim, a method for this using tidyr would be:
seuratObj <- addMetaData(seuratObj, ES)
seurat.meta <- [email protected]
summary <- seurat.meta %>%
group_by(variable) %>%
summarise(across(colnames(ES), median))
#You can make this ggplot friendly with
summary.melt <- reshape2::melt(summary)
Thanks,
Nick
from escape.
Hi @ncborcherding ,
Sorry for the stupid question, but I havent gotten this to work.
If I have a seurat object called data
and an erichIT obj called ES
where I have performed the following:
seurat.meta <- data$meta.data
summary <- seurat.meta %>%
group_by("celltype") %>% #celltype being the slot of metadata I would want to create averages for
summarise(across(colnames(ES), median))
summary.melt <- reshape2::melt(summary)
The output doesnt make sense, its just some median value of all cells, not seggregated data based on a meta data slot i.e. celltype. If we dont do this somehow we wont be able to plot an average heatmap of certain strings of GO types..... any suggestions?
The goal is to make a heatmap possibly using ditto similar to what we do natively for all cells, but showing averages instead of all cell values.
Cheers and thanks again!
from escape.
For now this is what im doing....would be gerat to have the heatmap function work as well!!!
from escape.
Hey @Dragonmasterx87
I think you might have an error in your tidy grammar - instead of "celltype", it should be celltype with no quotes. With quotes, it ends up summarizing across all cells instead of looking for a variable.
So it should read like this:
seurat.meta <- data$meta.data
summary <- seurat.meta %>%
group_by(celltype) %>% #here is the change
summarise(across(colnames(ES), median))
summary.melt <- reshape2::melt(summary)
Hope that helps,
Nick
from escape.
Related Issues (20)
- plotpathway() : sort by seurat clusters? Also, can I just keep the violin plot, but not the individual dots. HOT 1
- masterPCAPlot HOT 2
- Subsetting objects by cluster for visualization HOT 1
- I have problem with the format of my input data HOT 14
- Contour lines on tSNE/UMAP HOT 1
- Visualization of Enrichment HOT 1
- Improve computational time for EnrichIt(), performPCA(), and masterPCAplot HOT 1
- Median of getSignificance and multi_dittoPlot() don't match HOT 2
- masterPCAplot bug HOT 1
- Saving heatmap HOT 1
- enrichmentPlot did not finish HOT 3
- enrichIT values-negative scores HOT 3
- Differentially expressed genes in enrichment pathways HOT 3
- getSignificance very memory intensive when fit = ANOVA HOT 3
- about using a subset of groups in visualization HOT 8
- Batch effect correction HOT 2
- About ANOVA results viz HOT 3
- How to add significant differences between groups of variables in a figure HOT 1
- enrichIT fails due to " file names with spaces do not work properly on this platform" HOT 1
- Leading edge subset
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from escape.