Commit 2c2dede9 authored by jbracher's avatar jbracher
Browse files

Correction in server.

parent 6b227250
......@@ -139,16 +139,21 @@ shinyServer(function(input, output, session) {
reference <- truth_temp$value[grepl(input$select_date, as.character(truth_temp$time))]
truth_temp$value <- truth_temp$value - reference
colnames(truth_temp) <- c("time", "value")
plot_data$truth <- truth_temp
temp <- truth_temp
}
if(input$select_target == "temperature"){
plot_data$truth <- dat_truth$temperature
temp <- dat_truth$temperature
}
if(input$select_target == "wind"){
plot_data$truth <- dat_truth$wind
temp <- dat_truth$wind
}
temp$time <- rev(temp$time)
temp$value <- rev(temp$value)
plot_data$truth <- temp
# get selected models from input:
plot_data$select_models <- c(input$select_models1,
......@@ -216,6 +221,12 @@ shinyServer(function(input, output, session) {
colnames(points) <- colnames(lower) <- colnames(upper) <-
colnames(scores) <- c("x", "y")
intervals <- rbind(lower, upper[nrow(upper):1, ])
# reverting necessary to avoid bug with mouseovers (don't know why)
points$x <- rev(points$x)
points$y <- rev(points$y)
intervals$x <- rev(intervals$x)
intervals$y <- rev(intervals$y)
# store:
plot_data[[mod]] <- list(points = points, intervals = intervals, scores = scores)
......
Supports Markdown
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