Comments (5)
Answering your questions in reverse order,I have added the ability to render as SVG
.
- reinstall the package
devtools::install_github("JohnCoene/echarts4r")
- Set
renderer="svg"
ine_charts
Even using svg the visualisation requires the libraries (<script></script>
) so I'm unsure it will help including them in Word document.
However, I see two options to include them in Word.
- Open you visualisation in your browser,
echarts4r
default to will width and height of your screen so the resulting screen shot might be clearer. If you're in RStudio, check the top of the Viewer, there's a button to open in browser. - Use the built-in save as image tool, it might also return a clearer image.
library(echarts4r)
USArrests %>%
e_charts(UrbanPop) %>%
e_line(Assault) %>%
e_toolbox_feature(feature = c("saveAsImage")) # adds ability to save plot as image in the top right
Normally you would not save the plot as an image, you would save the whole widget.
# plot as object
USArrests %>%
e_charts(UrbanPop) %>%
e_line(Assault) -> plot
# save plot
htmlwidgets::saveWidget(plot, file = "plot.html")
Let me know if this is unclear, please close if this answers your question.
from echarts4r.
Thank you sou much. So great!
from echarts4r.
@JohnCoene Could you please add a functionality to be able to save the images?? For me it is a big disadvantage that these plots cannot be saved easily to png, for example. The png() -> plot -> dev.off() doesn't work either.
from echarts4r.
These are interactive charts that are ultimately meant for HTML outputs and it's difficult to provide an automated/reproducible way to save them as PNG, there is an old opened issue on htmlwidgets on the topic. I'm afraid webshot does not work properly with echarts4r so I?m out of solutions at this stage.
from echarts4r.
Webshot2 works like a charm.
from echarts4r.
Related Issues (20)
- timeline with multiple-y-axis setting y axis doesn't work
- timeline with multiple-y-axis setting y axis doesn't work
- e_bar chart combine with e_pie chart HOT 3
- Formatter with ec.clmn HOT 1
- e_river HOT 2
- Race and Waterfalls Charts HOT 6
- 'Cannot find function renderEcharts4r' error in Shiny Quarto document HOT 1
- Problem chaining e_text_g for multiple text placement HOT 2
- Question on shared dataset charts HOT 4
- `e_showtip_p`/ `e_dispatch_action_p` not working in modularized shiny app, attempting to debug with local fork but `debugger` doesn't register in the `addCustomMessageHandler` HOT 2
- How can I change the height and width of the elements (rectangles) on the heat map? HOT 3
- Themes from theme builder needs editing
- Make echarts4r available for webR HOT 1
- [Bug] on example code of Histogram HOT 1
- How to give each grid its own axis maximum? HOT 1
- e_radar not supporting group_by? HOT 1
- Scoring ring HOT 4
- Formatting dataView HOT 2
- margin not working when there are multiple groups of series HOT 10
- leaflet broken
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 echarts4r.