I am developing a R shiny application. I have a problem in if Loop.
I have code as following.
if (input$league !="anything"){
data <- data[(data$home_team | data$away_team) == input$league,]
}
The problem is Error in |: operations are possible only for numeric, logical or complex types. but it works in the loop if I do not have or(||) condition