stepUI<- function(id){ ns<-NS(id) echarts4rOutput("elaplot") } stepServer<-function(id, dat){ moduleServer( id, function(input,output,session){ output$elaplot<- renderEcharts4r({ dat |> e_charts(cost_gl) |> e_bar(Plan, name = "Plan", color="gray") |> e_step(Actual, name = "Actual", color="red") |> e_axis_labels(x = "GL+Cost Center", y="Deviation") |> e_title("Selected Cost Centers") |> e_tooltip() |> e_legend(right = 100) |> e_datazoom(x_index = 0, type = "slider") |> e_datazoom(y_index = 0, type = "slider") |> e_toolbox_feature(feature = c("saveAsImage","dataView")) |> e_theme("chalk") }) } ) }