R 如何在光面内渲染网格镜

R 如何在光面内渲染网格镜,r,plot,shiny,render,R,Plot,Shiny,Render,尽管包含了RenderRelliscope功能,但网格镜似乎无法在shiny中使用。你们谁能帮我确认一下吗 尽管这些链接似乎有所帮助: 这是个问题,但帮不了我 库(闪亮) 安装程序包(“gapminder”) 图书馆(gapminder) devtools::安装github(“hafen/Grilliscopejs”) 图书馆(格子镜) 用户界面 library(shiny) install.packages("gapminder") library(gapminder) devtools

尽管包含了RenderRelliscope功能,但网格镜似乎无法在shiny中使用。你们谁能帮我确认一下吗

尽管这些链接似乎有所帮助:

这是个问题,但帮不了我

库(闪亮)
安装程序包(“gapminder”)
图书馆(gapminder)
devtools::安装github(“hafen/Grilliscopejs”)
图书馆(格子镜)
用户界面
library(shiny)
install.packages("gapminder")
library(gapminder)
devtools::install_github("hafen/trelliscopejs")
library(trelliscopejs)
ui <- fluidPage(

  # App title ----
  titlePanel("Hello trelliscope in Shiny!"),

  # Sidebar layout with input and output definitions ----
  fluidPage(

    # Main panel for displaying outputs ----
    mainPanel(

      # Output: Histogram ----
      trelliscopeOutput("plot", width = "100%", height = "400px")

    )
  )
)


server <- function(input, output) {

  output$plot <- renderTrelliscope(
    qplot(year, lifeExp, data = gapminder) +
      xlim(1948, 2011) + ylim(10, 95) + theme_bw() +
      facet_trelliscope(~ country + continent,
                        nrow = 2, ncol = 7, width = 300, as_plotly = TRUE)

    )
  }

shinyApp(ui, server)