Unable to compare/calculate dateinput value in Flexdashboard.

In development of Flexdashboard want filter out and for new feature creation use date input.
as per date selection result update but it doesn't work.

---
title: "Oops"
social: menu
runtime: shiny
output: 
  flexdashboard::flex_dashboard:
    orientation: rows
    vertical_layout: fill
---
Inputs {.sidebar}
-------------------------------------
```{r}

default_report_date <- as.Date("2019-05-01")

# Add Date Picker for Generate report Based on It.
dateInput("RDate",
  label = "Report Date",
  value = "2019-05-01",
  min = NULL,
  max = NULL,
  format = "yyyy-mm-dd",
  startview = "month",
  language = "en",
  width = NULL
)
#default_report_date <- as.Date("2019-05-01")
` ` `
Raw_data_1 <- mutate(Raw_data_1,OT_Due_date = ifelse(Raw_data_1$DueDate >= input$RDate,"Future",
           ifelse((Raw_data_1$Received >=Raw_data_1$Ordered) & (Raw_data_1$LastRcvd >= Raw_data_1$DueDate),
                  "On Time","Late")
         ))

Error in as.Date(input$RDate) : object 'input' not found

Based on date selected from UI want to create new features and based on that new features plotting Chart and report table.

How to do it in flexdashboard?

This topic was automatically closed 54 days after the last reply. New replies are no longer allowed.