Hi all,
I am trying to apply lapply function as shown below
Hardcoded
fluidRow(column(6,plotlyOutput("A")),
column(6,plotlyOutput("B")))
<div class="row">
<div class="col-sm-6">
<div id="A" style="width:100%; height:400px; " class="plotly html-widget html-widget-output shiny-report-size shiny-report-theme"></div>
</div>
<div class="col-sm-6">
<div id="B" style="width:100%; height:400px; " class="plotly html-widget html-widget-output shiny-report-size shiny-report-theme"></div>
</div>
</div>
Instead of hard coding as shown above, I am applying lapply as below, but I need as above
cname_pas <- c("A","B")
asd <- lapply(cname_pas, plotlyOutput)
asd
[[1]]
<div id="A" style="width:100%; height:400px; " class="plotly html-widget html-widget-output shiny-report-size shiny-report-theme"></div>
[[2]]
<div id="B" style="width:100%; height:400px; " class="plotly html-widget html-widget-output shiny-report-size shiny-report-theme"></div>