Commit 062ef1dc authored by Stephanie Wegscheidl's avatar Stephanie Wegscheidl

little changes in naming

parent 0ef40149
Pipeline #443 failed with stages
......@@ -6,6 +6,7 @@ library(webshot)
library(knitr)
library(leaflet)
library(mapview)
library(ggplot2)
server <- function(input, output, session) {
......@@ -167,10 +168,10 @@ server <- function(input, output, session) {
}
})
#Continue to control page
observeEvent(input$controlSide, {
#Continue to view page
observeEvent(input$viewSite, {
updateTabItems(session, "tabs",selected = "controls")
updateTabItems(session, "tabs",selected = "views")
})
......@@ -179,7 +180,7 @@ server <- function(input, output, session) {
#Title Input
output$text <- renderText({ input$title })
#Histogram
#barchart
output$input_hist_x <- renderUI({
if (is.null(input$nut))
......@@ -228,7 +229,7 @@ server <- function(input, output, session) {
#})
#Linegraph
#linechart
output$input_line_x <- renderUI({
if (is.null(input$nut))
......@@ -252,14 +253,40 @@ server <- function(input, output, session) {
#DASHBOARD PAGE
#HISTOGRAM
#barchart
output$hist_box <- renderUI({
if(input$check_hist)
box( title="Histogram",
box( title="Barchart",
status= "warning",
solidHeader = TRUE,
collapsible = TRUE,
plotOutput("plot1", height = 250))
plotOutput("hist", height = 250))
})
#HIS VIEW
output$hist <- renderPlot({
print("hist wird aufgerufen")
a=1
for(a in 1:length(coconut.df$bluetooth.numOfBTDevices)){
#g <-geom_bar(mapping = NULL, data = , stat = "count",
# position = "stack", width = NULL, binwidth = NULL, na.rm = FALSE,
# show.legend = NA, inherit.aes = TRUE)
g <- ggplot(coconut.df, aes("timestamp","bluetooth"))
#g + geom_bar()
a=a+1}
g
#hist(bluetooth)
})
......@@ -283,48 +310,29 @@ server <- function(input, output, session) {
leafletOutput("map", height = 250))
})
# actual plot
# MAP VIEW
output$map <- renderLeaflet({
print("wird aufgerufen")
print("map wird aufgerufen")
m <<- leaflet()
x=1
m <- addTiles(m)
for(x in 1:length(coconut.df$gps.latitude)){
m <- addMarkers(m,lng=as.numeric(longitude[x]), lat=as.numeric(latitude[x])) #addPolylines does not work
m <- addCircleMarkers(m,lng=as.numeric(longitude[x]), lat=as.numeric(latitude[x]), radius = 1, color ="red") #addPolylines does not work
x=x+1}
m
})
#LINEGRAPH
#linechart
output$line_box <- renderUI({
if(input$check_line)
box( title="Linegraph",
box( title="Linechart",
status= "warning",
solidHeader = TRUE,
collapsible = TRUE,
plotOutput("plot1", height = 250))
})
# MAP
#function connectTheDots(data){
# c = []
# for(i in data._layers) {
# x = data._layers[i]._latlng.lat;
# y = data._layers[i]._latlng.lng;
# c.push([x, y]);
#}
#return c
#}
#pathCoords = connectTheDots(window.geojson);
#pathLine = L.polyline(pathCoords).addTo(m)
#DownloadButton
......@@ -347,7 +355,7 @@ server <- function(input, output, session) {
#print(appdir)
#appshot(appdir, "01_hello.png")
leaflet.print(m)
#leaflet.print(m)
......
......@@ -14,7 +14,7 @@ ui <- dashboardPage(
id="tabs",
menuItem("Upload", tabName = "upload", icon =icon("upload")),
menuItem("Data", tabName = "data", icon =icon("list")),
menuItem("Contols", tabName = "controls", icon = icon("cog")),
menuItem("Views", tabName = "views", icon = icon("cog")),
menuItem("Dashboard", tabName = "dashboard", icon = icon("dashboard")),
menuItem("Help", tabName = "help", icon = icon("book"))
)
......@@ -41,8 +41,7 @@ ui <- dashboardPage(
"text/json",
"text/comma-separated-values,text/plain",
".json")),
actionButton("dataSite", "next
")
actionButton("dataSite", "Go to Data")
),
......@@ -58,19 +57,19 @@ ui <- dashboardPage(
h2("CoCoQuest Data here:"),
h4("Last Loaded CoCoQuest Data: "),
textOutput("lastLoadedQuest"),
h4("Starttime: "),
textOutput("totalStarttime"),
#h4("Starttime: "),
#textOutput("totalStarttime"),
dataTableOutput("quest"),
actionButton("controlSide", "next")
actionButton("viewSite", "go to Views")
),
# Controls tab content
tabItem(tabName = "controls",
h2("Controls here:"),
tabItem(tabName = "views",
h2("Views here:"),
textInput("title", "Title", " "),
#HISTOGRAM
checkboxInput("check_hist", "Histogram", FALSE),
#Barchart
checkboxInput("check_hist", "Barchart", FALSE),
#uiOutput("check_hist"),
uiOutput("input_hist_x"),
uiOutput("input_hist_y"),
......@@ -78,14 +77,14 @@ ui <- dashboardPage(
checkboxInput("check_time", "Timeline", FALSE),
uiOutput("input_time_x"),
uiOutput("input_time_y"),
#Linechart
checkboxInput("check_line", "Linechart", FALSE),
uiOutput("input_line_x"),
uiOutput("input_line_y"),
#MAP
checkboxInput("check_map", "Map", TRUE),
uiOutput("input_map"),
#uiOutput("input_map_y"),
#LINEGRAPH
checkboxInput("check_line", "Linegraph", FALSE),
uiOutput("input_line_x"),
uiOutput("input_line_y"),
actionButton("dashboardSite", "go to dashboard")
),
......@@ -104,8 +103,8 @@ ui <- dashboardPage(
uiOutput("hist_box"),
uiOutput("time_box"),
uiOutput("map_box"),
uiOutput("line_box")
uiOutput("line_box"),
uiOutput("map_box")
),
actionButton("screenshot","Download")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment