Hi Stefan, Thanks, Yes you are right. I mean r_data$globalVar2 instead input$globalVar2. which r_data is a new env used to store global variables. The question is: Some functions run with variables returned from ui.R (input$var1) and in some case theses variables are saved as global variable to avoid re-computing. when I check R CMD, the input$var1 is not found. How to avoid this issue? Thanks, Karim On Tue, May 3, 2016 at 3:46 PM, Stefan Haunsberger <
stefan.haunsberger at gmail.com> wrote:
Hi Karim, I assume this is because the input parameter only assess the ones that are passed on from the ui-environment. The global variables are available without the 'input' prefix anyways. For example, if you declared *globalVar2* as a global variable (let's say in a global.r) then you don't need the input$ prefix. Variables declared within the ui-function body need to be addressed by input$. I hope that helps. Cheers, Stefan On Tue, May 3, 2016 at 1:57 PM Karim Mezhoud <kmezhoud at gmail.com> wrote:
Dear R,
usually, Shiny app uses global variables saved in a session.
These variables can be returned by client web page (checkbox or select).
for example:
FUN1 <- function(input$var1){
a <- input$car1 + input$globalVar2
return (a)
}
when I run check package I got error like
object input$globalVar2 not found.
Also the error is possible in running examples. The global variable or
input$var are not found in shiny app.
How we can avoid these issues.
Thanks,
Karim
[[alternative HTML version deleted]]
_______________________________________________ Bioc-devel at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/bioc-devel