Hi
This is the output of the program below. I am getting what I want; a list of lists, however, I do not understand why a list is icluded in (c) and the elements of the list start and end with a backwards slash in between quotation marks. The output in the IDE dispays the "backwards slash", however the backwards slash does not appear in this editor - may be you can reporduced them in RStudio. How can I eliminate those characters - c("backwrads slash") - ? For instance,
a = list()
b = anyvalue
a <- appemd(a, list(b))
would produce [1]"c("a","\b")". How can I eliminate those characters from the list of lists?
Thanks,
[1] "c(\"150413_JF_GPeps_SIDtarg_GPstdMix_Tryp_2runs_v3_PSMs.txt\", \"160824_JF_udep_tryp_Hi_SIDdda_FULL_NewParse-(05)_PSMs.txt\") 3"
[2] "c(\"160824_JF_udep_tryp_Hi_SIDdda_FULL_NewParse-(05)_PSMs.txt\", \"JF_160426_Dep2Plas_ctryp_Gpep_SIDtargFULL__PSMs.txt\") 3"
[3] "c(\"160824_JF_udep_tryp_Hi_SIDdda_FULL_NewParse-(05)_PSMs.txt\", \"JF_160426_Dep2Plas_ctryp_Gpep_SIDtargFULL__PSMs.txt\") 3"
ui <- fluidPage(
headerPanel("Test"),
#textInput('txt','','Text'),
selectInput("filescombine",label = h5(strong("PLEASE CHOSE FILES TO COMBINE. To undo selection select the selected file again and press the delete key on your keyboard.
If you wish to make more sets, PLEASE PRESS ADD BUTTON AND CHOSE FILES TO COMBINE")),c(Choose='', list.files("~/Development/fileTest/GLYCOUNT/DATA")), multiple=TRUE, selectize=TRUE),
actionButton('add','add'),
verbatimTextOutput("list")
)
server <- function(input, output, session){
myValues <- reactiveValues(List = list())
observe({
if(input$add > 0){
#myValues$List <- c(isolate(myValues$List), isolate(list(input$txt)))
myValues$List <- c(isolate(myValues$List), isolate(list(input$filescombine)))
}
})
output$list<-renderPrint({
myValues$List
result <- receivelist(myValues$List)
value <- paste(result$x, result$L)
value
})
}
receivelist <- function(myList){
x <- list()
x <- append(x, myList)
L <- length(x)
#print(paste(x, length(x)))
list(x = x, L = L)
}
shinyApp(ui = ui, server = server)