Comments (4)
@guidohooiveld Will be fixed in #260
test_treeplot.pdf
from enrichplot.
You did not show your full code, but if you create the input list for the function compareCluster
using the order you would like to, these order is retained in the resulting treeplot.
Admittedly, the resulting plot is not nice; ideally the labels should be rotated 90 degrees, and also the dots are positioned outside the colored clusterPanel...
@huerqiang : could you please have a look at these 2 issues (option to rotate labels, and correct position dots)?
Thanks!
> ## load libraries
> library(clusterProfiler)
> library(enrichplot)
> library(org.Hs.eg.db)
> library(ggplot2)
>
> ## load sample data
> data(gcSample)
>
> ## keep first 5 samples
> gcSample1 <- gcSample[c(1:5)]
>
> ## rename first 5 samples
> ## use increasing order
> names(gcSample1)[1:5] <- c("12", "146", "682", "1450", "1960")
>
> ## run enrichGO
> data.out.bp1 <- compareCluster(gcSample1, fun="enrichGO",
+ OrgDb="org.Hs.eg.db", ont="BP", pvalueCutoff=0.05)
>
> data.out.bp1 <- pairwise_termsim(data.out.bp1)
>
>
> ## make treeplot
> ## note: changed showCategory to 3
>
>
> p1 <- treeplot(data.out.bp1,showCategory=3,
+ clusterPanel.params = list(clusterPanel = "dotplot") )
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
ℹ invalid tbl_tree object. Missing column: parent,node.
ℹ invalid tbl_tree object. Missing column: parent,node.
>
> ## show picture
> p1
>
> ## rename samples, but now use random order
> gcSample2 <- gcSample[c(1:5)]
> names(gcSample2)[1:5] <- c("146", "12", "682", "1960", "1450")
>
> ## run enrichGO again
> data.out.bp2 <- compareCluster(gcSample2, fun="enrichGO",
+ OrgDb="org.Hs.eg.db", ont="BP", pvalueCutoff=0.05)
>
> data.out.bp2 <- pairwise_termsim(data.out.bp2)
>
> p2 <- treeplot(data.out.bp2,showCategory=3,
+ clusterPanel.params = list(clusterPanel = "dotplot") )
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
! # Invaild edge matrix for <phylo>. A <tbl_df> is returned.
ℹ invalid tbl_tree object. Missing column: parent,node.
ℹ invalid tbl_tree object. Missing column: parent,node.
>
> ## show picture
> p2
>
>
from enrichplot.
@guidohooiveld It will be fixed in a few days.
from enrichplot.
@huerqiang : thanks for implementing a fix for this so quickly! Much appreciated.
from enrichplot.
Related Issues (20)
- Error in offspring.tbl_tree_item(.data = .data, .node = .node, tiponly = tiponly, : could not find function "offspring.tbl_tree_item" HOT 3
- Recolouring treeplot HOT 1
- UseMethod("rescale") error using cnetplot() function HOT 5
- Upsetplot Question
- Feature Request: Enhancements for cnetplot Function in enrichplot Package
- show all nodes but show select labels in emapplot HOT 3
- Help with the new gradient colors HOT 3
- emapplot and cnetplot customization (compareCluster) HOT 5
- gseaScores() HOT 1
- why does my treeplot only appear partially? HOT 2
- enhancement: cnetplot gene vs gene set node aesthetics customization
- add color setting for add_node_label function
- unexpected change of default colors/theme with enrichplot HOT 7
- pairwise_termsim Throws Error if No Significant Gene Sets HOT 4
- dotplot shows only one term HOT 2
- Fractional Genes
- compareCluster dotplot: how to modify the genesets order HOT 1
- The shape of the point changed when combining two dotplot figures into one figure. HOT 4
- How can I change the width of each coloum in the heatmap in the treeplot?
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 enrichplot.