-
Notifications
You must be signed in to change notification settings - Fork 0
/
ui.R
66 lines (64 loc) · 2.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
# load up the packages
library(shiny)
library(shinythemes)
library(shinycssloaders)
library(readr)
library(tidyverse)
library(Rmisc)
library(tools)
require(showtext)
library(hrbrthemes)
library(fontawesome)
# download a webfont
sysfonts::font_add_google(name = "Roboto Condensed", family = "Roboto Condensed",
regular.wt = 400, bold.wt = 700)
showtext_auto()
fluidPage(
theme = shinytheme("sandstone"),
title = "Soil CO\u2082 flux data",
plotOutput("contents1") %>% withSpinner(type = getOption("spinner.type", default = 4)),
hr(),
fluidRow(
column(3,
h3("Soil CO\u2082 flux data"),
h4("1."),
fileInput('csv_data',
label = list(icon("table"), "Upload csv file"),
accept = c('sheetName', 'header'),
multiple = FALSE),
p(a(list(icon("github"), "Source code"), href = "https://github.com/Vojczech/Soil_flux_app", target="_blank"))
),
column(4,
h4("2."),
offset = 1,
textInput("plot_title", 'Write plot title',
placeholder = "e.g. nitrogen addition treatment"),
dateRangeInput('date_range',
label = list(icon("calendar-alt"), "Filter by date"),
start = Sys.Date() - 3, end = Sys.Date(),
separator = " to ", format = "yy/mm/dd",
startview = 'month', language = 'en', weekstart = 1
),
radioButtons("x_scale", "Label X axis by:",
c("day", "week", "month", "year"),
inline = TRUE,
selected = "week")
),
column(4,
h4("3."),
radioButtons("plot_type",
label = list(icon("chart-area"), "Choose plot type"),
choices = c("atmospheric/soil concentration" = "atmo_soil", "soil flux" = "flux"),
selected = c("flux")),
uiOutput("ui"),
br(),
downloadButton("download_plot",
"Download final plot"),
radioButtons("download_extension",
label = "",
choices = c("pdf" = "pdf", "png" = "png", "svg" = "svg"),
selected = "pdf",
inline = TRUE)
)
)
)