-
Notifications
You must be signed in to change notification settings - Fork 0
/
ui.R
222 lines (127 loc) · 8.36 KB
/
ui.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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
library(shiny)
## I want three pages:
# first an introductory page with my name, contact details, cv for pdf download and a funny app
# second an analysis of how people in different Bundesländer view XYZ-
# third an analysis of patterns regarding
# Define UI for application that draws a histogram
shinyUI(fluidPage(theme = shinytheme("lumen"),
tags$script("source/scrollback_function.js"),
#theme = "css_layout.css",
# https://rstudio.github.io/shinythemes/
withMathJax(),
# Application title
titlePanel("Mio's Dashboard hobby room"),
tabsetPanel(
tabPanel(title = "Overview",
br(),
div("Hi, there"),
div("you have found your way to my Dashboard hobby room, a small and hopefully convenient way to give you a small demonstration of my interests and competences in data analytics and data visualisation."),
br(),
div(""),
sidebarPanel(width = 3,
style = "position:fixed;width:22%;",
#tags$img(scr = "www/mio_bild_farbe.jpg", height = 300, width = 200),
HTML('<img src="mio_bild_farbe.jpg", height="150px" width="150px", style="align:left"</img>'),
div("Mio Hienstorfer-Heitmann"),
div("1992/01/13"),
div("Based in Rhineland, Germany"),
div("mio.hiehei@gmail.com"),
br(),
downloadButton(outputId = "downloadcv", label ="Download CV"),
),
column(width = 8,
div("On this page, check out this very carefully conducted analysis on surname length and producvitity in the workplace. The data was collected from personal and very objective opinion."),
br(),
div("Hover over the points in the plot to find out more."),
br(),
br(),
plotlyOutput("plotly_surname"),
br(),
div("You can see that there is a very strong visual relationship between the number of letters a person has in their surname and their workplace productivity."),
br(),
actionButton("button_surname_detail", "Find out more"),
br(),
br(),
conditionalPanel(
condition = "input.button_surname_detail != 0",
br(),
tags$iframe("www/surname_details_html.html"),
br(),
tableOutput("surname_var_desc_table"),
tags$iframe("www/surname_details_regression.html"),
br(),
h4("Simulate Regression output"),
tableOutput("surname_reg_table"),
selectInput("var1_ols",
"Variable 1",
choices = unique(colnames(X[,-1]))),
conditionalPanel(condition = "var1_ols != 0",
uiOutput("var1_sel")
),
br(),
textOutput("sim_para_text"),
br(),
checkboxInput("check_see_data", "See the collected data to compare", value = FALSE),
plotOutput("sim_plot_surname")
)
)
),
tabPanel(title = "Polarisation of German Volksparteien",
br(),
tags$iframe("www/ca_text.html"),
br(),
br(),
## Filter for time zone
sliderInput(inputId = "ca_slider",
label = "Choose an area of time",
min = min(df_merged$date),
max = max(df_merged$date),
value = c(min(df_merged$date), max(df_merged$date))
),
br(),
br(),
dygraphOutput("plot_ca"),
),
tabPanel(title = "Schools in North-Rhine-Westphalia (still under construction)",
column(width = 3,
sliderInput(inputId = "no_pupils",
label = "Number of Pupils",
min = min(schools_df_omitted$SCHUELER),
max = max(schools_df_omitted$SCHUELER),
value = c(quantile(schools_df_omitted$SCHUELER, 0.25), quantile(schools_df_omitted$SCHUELER, 0.75))),
br(),
pickerInput(inputId = "ort_school",
label = "City of School",
choices = sort(unique(schools_df_omitted$ORT)),
selected = sort(unique(schools_df_omitted$ORT)),
options = pickerOptions(actionsBox = TRUE),
multiple = TRUE),
br(),
checkboxInput("na",
"Select NA Values for inhabtitants",
value = FALSE),
bsTooltip(id = "na",
title = "Some data on inhabitants of a town is not present. Do you want to filter that data out?",
placement = "right",
trigger = "hover"),
conditionalPanel(
condition = "input.na == false",
sliderInput(inputId = "size_munip",
label = "No of inhabitants in school's town",
min = min(schools_df_omitted$einwohner, na.rm = TRUE),
max = max(schools_df_omitted$einwohner, na.rm = TRUE),
value = c(min(schools_df_omitted$einwohner , na.rm = TRUE), max(schools_df_omitted$einwohner, na.rm = TRUE)))
),
br(),
pickerInput(inputId = "type_school",
label = "School Type",
choices = sort(unique(schools_df_omitted$SCHULFORM)),
selected = sort(unique(schools_df_omitted$SCHULFORM)),
options = pickerOptions(actionsBox = TRUE),
multiple = TRUE)),
column(width = 7,
leafletOutput("schoolmap")
)
)
)
))