R Markdown pdf Partially color cell background (data bar)
Excel has this function called "data bar" that allow conditional formatting based on the cell value with respective length. This function can be done with "formattable" in R using the formatter and color_bar. however, the result of this is a html widget which cannot be shown in pdf. Here's some options I have tried: webshot: takes a screenshot of the widget and then I can import into pdf as an image. Not very efficient also formattable is not the best option as it doesn't allow for nested tables xtable/pander - doesn't allow me to add conditional formatting kable + kableExtra: this one I had