hrbrmstr / metricsgraphics

:chart_with_upwards_trend: htmlwidget interface to the MetricsGraphics.js D3 chart library
http://hrbrmstr.github.io/metricsgraphics/
Other
132 stars 35 forks source link

metricsgraphics_html returned an object of class `list` instead of a `shiny.tag` #54

Open jvcasillas opened 1 year ago

jvcasillas commented 1 year ago

When I run the following code from the documentation:

data.frame(year=seq(1790, 1970, 10), uspop=as.numeric(uspop)) %>%
  mjs_plot(x=year, y=uspop) %>%
  mjs_line()

I get the following message:

Warning message: In widget_html(name = class(x)[1], package = attr(x, "package"), : metricsgraphics_html returned an object of class list instead of a shiny.tag.

The plot is produced in RStudio, but does not show up in an Rmd file when it is rendered. In ideas as to how to get this working again in an Rmd file?