title: conditionally output different colored text in Shiny
body: <p>I would like Shiny to print out some different color text depending on the size of a vector. I was thinking something like:</p>
  
  <pre><code>  output$some_text &lt;- renderText({ 
      if(length(some_vec) &lt; 20){
        paste("This is red text")
        &lt;somehow make it red&gt;
      }else{
      paste("This is blue text")
        &lt;somehow make it blue&gt;
  </code></pre>
  
  <p>...but then I realized, I'm doing this in the server, not the UI.</p>
  
  <p>And, as far as I know, I can't move this conditional logic into the UI.</p>
  
  <p>For example, something like this won't work in the UI:</p>
  
  <pre><code>    if(length(some_vec)&lt; 20){
           column(6, tags$div(
           HTML(paste("This text is ", tags$span(style="color:red", "red"), sep = ""))
        )}
      else{
           tags$div(HTML(paste("This text is ", tags$span(style="color:blue", "blue"), sep = ""))
  )}
  </code></pre>
  
  <p>Does anyone have any creative ideas?</p>