From 39752fb45a58950236e4ebd124c90792f6623304 Mon Sep 17 00:00:00 2001 From: Federico Marini Date: Thu, 30 Jul 2020 11:36:28 +0200 Subject: [PATCH 1/5] R1-point2: Sorting the columns of the preview table aphabetically --- app.R | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app.R b/app.R index 98251c1..a95e4f6 100644 --- a/app.R +++ b/app.R @@ -40,6 +40,9 @@ createLinkGO <- function(val) { message("Loading R data...") load("trendseq.RData") +# sorting columns for KDmat? +KDmat <- KDmat[, order(colnames(KDmat))] + # these objects needed to be updated in newer Bioc versions # txBygene <- updateObject(txBygene,verbose = FALSE) utrs <- updateObject(utrs, verbose = FALSE) From 69d5e160f909e872d1d821e245da582692508cd4 Mon Sep 17 00:00:00 2001 From: Federico Marini Date: Thu, 30 Jul 2020 11:37:20 +0200 Subject: [PATCH 2/5] R1-point1: Fixing the column with gene names to be always viewed even while scrolling --- app.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.R b/app.R index a95e4f6..b18b1c2 100644 --- a/app.R +++ b/app.R @@ -716,7 +716,7 @@ server <- function(input, output, session) { scrollY = 407, scroller = TRUE, pageLength = 50, - fixedColumns = FALSE + fixedColumns = TRUE ) ) %>% formatRound(colnames(table), digits = 3) %>% From f85c25bdca67f55e29e15608b2fb2f6d386bdb06 Mon Sep 17 00:00:00 2001 From: Federico Marini Date: Thu, 30 Jul 2020 11:38:18 +0200 Subject: [PATCH 3/5] R1-point3: Adding copy/print/download buttons for the generated tables --- app.R | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/app.R b/app.R index b18b1c2..fe879a4 100644 --- a/app.R +++ b/app.R @@ -928,12 +928,21 @@ server <- function(input, output, session) { paste0(colnames(table), "_kd") DT::datatable( table, + extensions = "Buttons", colnames = c("Gene" = 1), options = list( scrollX = TRUE, # scrollY = 300, searching = TRUE, - paging = FALSE + paging = FALSE, + dom = 'Bfrtip', + buttons = + list('copy', 'print', list( + extend = 'collection', + buttons = c('csv', 'excel', 'pdf'), + text = 'Download' + ) + ) ) ) %>% formatStyle("Gene", @@ -956,13 +965,21 @@ server <- function(input, output, session) { kdtable, colnames = c("Gene" = 1), selection = "single", - extensions = c("FixedColumns"), + extensions = c("FixedColumns", "Buttons"), options = list( scrollX = TRUE, scrollY = 480, paging = FALSE, searching = TRUE, - fixedColumns = FALSE + fixedColumns = FALSE, + dom = 'Bfrtip', + buttons = + list('copy', 'print', list( + extend = 'collection', + buttons = c('csv', 'excel', 'pdf'), + text = 'Download' + ) + ) ) ) %>% formatStyle("Gene", From f858d9e73924926aafbae2ce8bb5c4890009ba67 Mon Sep 17 00:00:00 2001 From: Federico Marini Date: Thu, 6 Aug 2020 14:05:52 +0200 Subject: [PATCH 4/5] failsafe when no term is strictly detected as enriched --- app.R | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app.R b/app.R index fe879a4..a788ee9 100644 --- a/app.R +++ b/app.R @@ -1037,7 +1037,13 @@ server <- function(input, output, session) { output$emap_ui <- renderUI({ if(!(nrow(createGoenrich()) > 0)) - return(NULL) + return( + tagList( + shiny::tags$br(), + shiny::tags$br(), + p(shiny::tags$em("You can not generate an enrichment map, no functional category has an adjusted p-value below 0.05...")) + ) + ) tagList( numericInput("emap_ngs", width = "25%", From 00ed4d052fa866b145a117ab9ff0f19b1cb7af6a Mon Sep 17 00:00:00 2001 From: Federico Marini Date: Thu, 6 Aug 2020 16:52:53 +0200 Subject: [PATCH 5/5] Button added also for the enrichment table --- app.R | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/app.R b/app.R index a788ee9..45d2995 100644 --- a/app.R +++ b/app.R @@ -40,7 +40,7 @@ createLinkGO <- function(val) { message("Loading R data...") load("trendseq.RData") -# sorting columns for KDmat? +# sorting columns for KDmat KDmat <- KDmat[, order(colnames(KDmat))] # these objects needed to be updated in newer Bioc versions @@ -1014,12 +1014,22 @@ server <- function(input, output, session) { ), rownames = FALSE, selection = "single", - extensions = c("FixedColumns"), + extensions = c("FixedColumns", "Buttons"), options = list( bInfo = 0, scrollX = TRUE, + scrollY = 480, fixedColumns = FALSE, - order = list(5, "asc") + paging = FALSE, + order = list(5, "asc"), + dom = 'Bfrtip', + buttons = + list('copy', 'print', list( + extend = 'collection', + buttons = c('csv', 'excel', 'pdf'), + text = 'Download' + ) + ) ), escape = FALSE ) %>%