ByrumLab / proteiNorm

Apache License 2.0
9 stars 5 forks source link

Issues with screenDim and controlsDAtest in app.R #5

Open Jens-VandePerre opened 2 years ago

Jens-VandePerre commented 2 years ago

Hi,

I am trying to run proteiNorm locally as the shiny app because of an issue I had in the online version at [(https://sbyrum.shinyapps.io/proteiNorm/)] . The issue online was the error: "Error: An error has occurred. Check your logs or contact the app author for clarification", in the place where the filter plots for the peptides should appear. I discovered that this is a general error in online shiny apps, but that it is often resolved by running the app locally. I also noticed in another issue thread that the app has to be ran locally to able to download the proces figures. I have installed all the packages listed at the top of the app.R file and also the additional packages requested by these listed packages. I have also directed source to the locations where I stored normFunctions.R and functions.R.

The first issue is in line 35 in app.R: screenDim <- .jrcall(default_toolkit, "getScreenSize") Here I get the error: Error in .jcall("RJavaTools", "Ljava/lang/Object;", "invokeMethod", cl, : java.awt.HeadlessException. This also results in a downstream error where the screenHeight argument is needed for body. This way ui <- dashboardPage(header, sidebar, body) is not working, because body is absent.

The second issue from line 56 until 64 in app.R: controlsDAtest <- list(h3("Test to be excluded:"), tags$div(align = 'left', class = 'multicol', checkboxGroupInput(inputId = "checkboxDAtestTests", label = NULL, choices = allChecks, selected = which(DAtestTests %in% "per"), inline = FALSE))) Where I get the error: Error in names(x)[emptyNames] <- as.character(x)[emptyNames] : NAs are not allowed in subscripted assignments.

Thanks in advance. I would be really grateful if the issues could be resolved, my master thesis sort of depends on it.

Best Jens

ttessie2 commented 2 years ago

I'm also running into the same error (NAs are not allowed in subscripted assignments).

ByrumLab commented 2 years ago

The DAtest code does not work with NAs. We have an imputation option so you can use one of the missing value imputation methods to handle zeros. I only use the imputation to run DAtest for evaluating stat methods.

ttessie2 commented 2 years ago

Sorry, I should have specified when I get this error. When I open the app.R in Rstudio and run the application I get: runApp() Error in names(x)[emptyNames] <- as.character(x)[emptyNames] : NAs are not allowed in subscripted assignments