Questions tagged [echarts4r]

Use this tag for questions related to the usage of the [echarts4r] package, which provides functions to facilitate making interactive charts in the R programming language, by leveraging the Echarts JavaScript library.

The package provides functions to make it easy to create interactive charts in the R programming language by leveraging the Javascript library which includes 36 chart types, themes, proxies and animations.

An overview and introduction to the package can be found on the package website.

105 questions
6
votes
1 answer

Animate plots using echarts4r when quarto slides are on-screen

I am making a Revealjs presentation using Quarto in R Studio. I am using the package {echarts4r} to make my plots. {echarts4r} comes with default animations. When I render the presentation the default animation has already loaded for all the…
Shubham
  • 220
  • 2
  • 10
5
votes
1 answer

add relevant information tooltip echarts4r boxplot outliers

I am trying to add some relevant hover information to the tooltip of a echarts4r plot. I want to make an boxplot that shows the user the name (or some other information) of the outliers. This is somewhat related to Add extra variables to tooltip pie…
L Smeets
  • 888
  • 4
  • 17
4
votes
1 answer

Is it possible to change borderColor for area bands (e_band2) in echarts4r?

Goal: In my plot, I would like to have different colors for the border and the area of an area band. The plot was created with echarts4r using the e_band2() function. Problem: In the documentation I read that area bands can be customized through…
Domi
  • 89
  • 5
4
votes
1 answer

How to increase number of breaks on x axis in echarts4r plot?

I am making a simple histogram in echarts4r, but I am struggling to override the default x axis labels. For example in the plot below, I would like to have a label at every 3rd, instead of intervals of 5. library(echarts4r) mtcars |> …
L Smeets
  • 888
  • 4
  • 17
3
votes
1 answer

Quarto figure labels break tooltip formatting for echarts plots

After adding a figure label to a quarto chunk that creates an echarts plot, the text in the tooltip becomes misaligned. This seems to be an issue only recently introduced. Here is an example without a figure label and the tooltip renders…
Giovanni Colitti
  • 1,982
  • 11
  • 24
3
votes
1 answer

"e_tooltip(formatter = )" how to display the interval instead of the average of the histogram column?

I have a histogram and the need to see not the average value of the histogram column (2.9 on the picture), but its interval (2.8-3.0). How to do it? Example code: iris %>% setDT() %>% e_charts() %>% e_histogram( Sepal.Width, …
Avraam
  • 146
  • 1
  • 10
3
votes
1 answer

e_facet using grouped data in echarts4r question

I really like the possibilities this package offers and would like to use it in a shiny app. however i am struggling to recreate a plot from ggplot to echarts4r library(tidyverse) library(echarts4r) data = tibble(time =…
3
votes
1 answer

How to show labels on the left side of the vertical line in a parallel coordinates plot created with echarts4r?

The context I know the following code produces the following plot library('echarts4r') dat <- structure(list( labels = c("string4", "string3", "string2", "string1"), quantity = c(19L, 10L, …
rdrg109
  • 265
  • 1
  • 8
3
votes
3 answers

Echarts4r have barplot start at value other than 0

I want to use echarts4r to plot a barplot where values above a cutoff are colored green and below red and the bars start at that value. If the cutoff is 0, we can use the answer provided here, for other values (eg 1 in the example below) this does…
David
  • 9,216
  • 4
  • 45
  • 78
3
votes
1 answer

How I can change the orient of labels on echarts4r?

Hi and thanks for reading this. I am trying to make a bar plot with value labels on echarts4r, but I can't change the orientation of the labels so that the values do not overlap. I tried orient = "vertical" but it doesn't work. My code is as…
3
votes
1 answer

Saving an echarts4r image via code (again)

I asked this question earlier here, but it was marked as duplicate and closed. Unfortunately the answer I was pointed to doesn't work.... So, again: I can produce an eCharts4r gauge like library(echarts4r) library(magrittr) CA_gauge <- e_charts()…
jerH
  • 1,085
  • 1
  • 12
  • 30
3
votes
0 answers

Programatically save an eCharts4r chart

I can produce an eCharts4r gauge like library(echarts4r) library(magrittr) CA_gauge <- e_charts() %>% e_gauge(4.1, "INCIDENCE", min=0, max=20, axisLine = list( linestyle = list( …
jerH
  • 1,085
  • 1
  • 12
  • 30
3
votes
1 answer

R echarts4r - format dates in axis

How can the date format be controlled in echarts4r? There is a formatter for currency, percentage and decimal but not for dates that I can see. Here's an example from https://rpubs.com/paul_simmering/echarts library(echarts4r) library(nycflights13)…
Vlad
  • 3,058
  • 4
  • 25
  • 53
2
votes
1 answer

echarts4r create pivotchart (subgroup x axis)

I want to recreate a version of a pivotchart in echarts4r with two subgroup x axis. By pivot chart I mean a chart that has two subgroups of x axis labels, like the one below. So far I found this SO answer that answers it for an echart but I cannot…
David
  • 9,216
  • 4
  • 45
  • 78
2
votes
1 answer

echarts4r: fix axis range across groups

I am creating a grouped bar chart like so: library(tidyverse) library(echarts4r) data("starwars") starwars %>% group_by(sex, eye_color) %>% summarise(height = mean(height, na.rm=TRUE)) %>% group_by(sex) %>% e_charts(x = eye_color,…
Dennis
  • 23
  • 5
1
2 3 4 5 6 7