-
Notifications
You must be signed in to change notification settings - Fork 1
/
ui_metaanalysis.R
executable file
·103 lines (98 loc) · 4.91 KB
/
ui_metaanalysis.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#########################################################################################################
tabPanel(
"Meta-analysis",
h1(HTML('<font color="tomato" face="Comic Sans MS"><center><b>Meta-analysis</b></center></font>')),
conditionalPanel(
condition = 'input["compare.select.table2"] == ""',
rnaseq2g.write.prompt("Meta-analysis will be available when results from 2+ DE methods are available.")
),
conditionalPanel(
condition = 'input["compare.select.table2"] != ""',
wellPanel(
rnaseq2g.write.header("Set up and run a meta-analysis"),
fluidRow(
column(
12,
div(style="display: inline-block;", h5(HTML("<b>Select DE methods to be included in meta-analysis:</b>"))),
div(style="display: inline-block;", HTML("   ")),
div(style="display: inline-block;", radioButtons('meta.select.group', '', list('Select none'=1, 'Select all'=2, 'Select random'=3), inline = TRUE))
),
column(
12,
wellPanel(
style = "border-color: darkgrey; border-style: dashed",
uiOutput('meta.select.box')
)
),
column(
12,
div(style="display: inline-block;",
selectizeInput('meta.select.method', label = 'Select meta-analysis method', width='240px',
choices = list(Simes='simes', Fisher='fisher', Average='average', Bonferroni='bonferroni', Max='max', Min='min'))),
div(style="display: inline-block;", HTML("      ")),
div(style="display: inline-block;", checkboxInput('meta.normalize.p', label='Normalize p values first', value=TRUE))
),
column(
12,
div(style="display: inline-block;", actionButton("meta.run", 'Run ', icon("paper-plane"), style=button.style, width='108px')),
div(style="display: inline-block;", HTML("   ")),
div(style="display: inline-block;", htmlOutput("meta.run.message"))
)
)
)
),
# Compare rankings of two methods
conditionalPanel(
condition = 'input["meta.compare.method"] != ""',
wellPanel(
rnaseq2g.write.header("Compare meta-analysis to individual DE methods"), br(),
fluidRow(column(
12,
div(style="display:inline-block;", selectInput('meta.pv.type', 'Select plot', list('Quantile-quantile'='1', 'P value ranking'='2', 'Venn diagram'='3'), width='200px')),
div(style="display:inline-block;", HTML(" ")),
div(style="display:inline-block;", selectInput('meta.compare.method', 'Select method', choices=list(), width='150px')),
div(style="display:inline-block;", HTML(" ")),
div(style="display:inline-block;", selectInput('meta.top.gene', 'Top genes', c=c('All', 10, 25, 50, 100, 250, 500), width='120px')),
div(style="display:inline-block;", HTML(" ")),
div(style="display: inline-block;", h4(HTML('<center>Download table</center>')),
radioButtons('meta.download.format', NULL, c('R', 'Text', 'Excel'), inline=TRUE)),
div(style="display: inline-block;", h4(HTML(" "))),
div(style="display: inline-block;",
tags$head(tags$style(".dC{float:center;} .dC{font-family: Courier New;} .dC{background-color: tomato;} .dC{border-color: black;} .dC{height: 75%;} .dC{width: 50px;} .dC{font-size: 11px;}")),
downloadButton('meta.download.button', label = '', class = 'dC'))
)),
fluidRow(
column(5, wellPanel(plotlyOutput('meta.plot.pv', width = '100%', height = '560px'))),
column(7, wellPanel(DT::dataTableOutput('meta.table.pv', width='100%')))
)
)
),
# Single gene details
conditionalPanel(
condition = 'input["meta.compare.method"] != ""',
wellPanel(
rnaseq2g.write.header("Show all results of a single gene"), br(),
fluidRow(
div(style="display:inline-block;", HTML(" ")),
div(style="display:inline-block;", textInput("meta.single.id", NULL, value = "")),
div(style="display:inline-block;", HTML(" ")),
div(style="display:inline-block", htmlOutput("meta.single.msg")),
conditionalPanel(
condition = 'input["meta.single.id"] != ""',
column(7, DT::dataTableOutput('meta.single.table', width='100%')),
column(
5,
plotlyOutput('meta.single.plot', width = '100%', height = '480px'),
h6(HTML(" ")),
fluidRow(
column(
12, align='center',
radioButtons('meta.single.type', NULL, list('Original count'='1', 'Normalized count'='2', 'Log2-transformed'='3'), selected = '2', inline = TRUE)
)
)
)
)
)
)
)
)