Comments (5)
I think adding an option to make it easy to add overlay text would be a nice addition to this package, so I'll leave this issue open...
from iheatmapr.
You would need to pass the annotations as a list of list, e.g.
plot <- iheatmap(data = data, layout = list(annotations = list(list(text = "hi", x = 0.5, y = 0.5, xref = "x", yref = "y"))))
Note that this kind of annotation will add a little arrow, which may not be what you want here... but can be addressed by adding showarrow = FALSE
from iheatmapr.
Thank you, greatly appreciate the help!
from iheatmapr.
Sorry to bug you again, but I have discovered a new issue related to this.
Under your suggestion, the annotation works well:
iheatmap(data = data, layout = list(annotations = list(list(text = "hi", x = 1, y = 1, xref = "x", yref = "y", showarrow = F))))
produces:
(please ignore the bar across the top, RStudio seemed to be glitching on image export)
However, when I try to do the same thing and add row labels, the annotation disappears:
iheatmap(data = data, layout = list(annotations = list(list(text = "hi", x = 1, y = 1, xref = "x", yref = "y", showarrow = F)))) %>% add_row_labels(ticktext = c("a", "b"))
produces:
I was thinking that the row labels might be "overriding" the annotations, so I tried to add them on afterwards via "modify_layout", but the problem persisted.
iheatmap(data = data) %>% add_row_labels(ticktext = c("a", "b")) %>% modify_layout(list(annotations = list(list(text = "hi", x = 1, y = 1, xref = "x", yref = "y", showarrow = F))))
produced:
I assume this is actually a bug, or perhaps I'm simply extending the package beyond its intended use.
from iheatmapr.
I would like to follow up on this issue.
from iheatmapr.
Related Issues (20)
- textangle messes-up the row or column labels HOT 1
- layout of colorbars of annotations
- Reverse dependency checks fail with `ggdendro` HOT 5
- Adding empty annotation causes an error HOT 2
- Single row heatmap does not show HOT 2
- Column annotation label disappeared HOT 10
- Scale the main_heatmap
- Add extra markings to specific cells
- Bug: error causes heatmap to disappear if it tries to re-plot after a plotly plot is rendered HOT 1
- iheatmapr in shiny is not responsive HOT 1
- renderIheatmap breaks when used with shiny::req HOT 3
- Using multiple colors for axis ticks HOT 2
- Add animation/slider function
- Decorate heatmap body
- [FEATURE REQUEST] Use with Chart studio HOT 1
- How to change the row order of the heatmap from Alabama to Wyoming ? [Question] HOT 4
- Buffer and size dendrogram argument to add_*_clustering
- iheatmapr doesn't work when on the same HTML page as a standard plotly widget HOT 1
- Resize width and height of html file using saveWidget or save_iheatmap
- CRAN deprecation HOT 3
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 iheatmapr.