Color DT table columns if there are matching with other columns

Is there a way to color columns if there are equal to other columns. Example

library(shiny)
library(DT)

ui <- fluidPage(
  dataTableOutput("iris")
)

server <- function(input, output, session) {
  output$iris <- renderDataTable({
    datatable(iris)
  })
}

shinyApp(ui, server)

Expected output Color Sepal.Length as green only when are equal to Sepal.width or else color as red. Is there a way to achieve this?

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

If you have a query related to it or one of the replies, start a new topic and refer back with a link.