The validate() function in shiny is generally used within a reactive({}) code block, and I have placed them in the blocks that involve retrieving data (in order to validate before any errors occur with using gene inputs to select feather columns).
Currently, there are four locations in the app where I separately validate gene input: dendrogram & expression table tabs, timecourse tab, single cell expression tabs, ranked clusters tab. It would be ideal to remove code duplication by validating within a function or a prior step before the code for tabs. I'm not sure how a function would work since validate() must be used in a reactive context.
The
validate()
function in shiny is generally used within areactive({})
code block, and I have placed them in the blocks that involve retrieving data (in order to validate before any errors occur with using gene inputs to select feather columns). Currently, there are four locations in the app where I separately validate gene input: dendrogram & expression table tabs, timecourse tab, single cell expression tabs, ranked clusters tab. It would be ideal to remove code duplication by validating within a function or a prior step before the code for tabs. I'm not sure how a function would work sincevalidate()
must be used in a reactive context.