I am outputting a table using shiny (with renderTable and tableOutput), is there a way to edit the format of the table and of the values within the table.
Specifically I want to
- Use comma as 1000 superator (i.e. change 1234567 to 1,234,567)
- Put a £ sign before every value in one column
- Make the final row bold
- Remove row names
So if you take the shiny reactivity e.g. as an example
runExample('03_reactivity')
This outputs a table 'view', the server.R code for it is
output$view <- renderTable({
head(datasetInput(), n = input$obs)
})
The ui.R code for it is
tableOutput("view")
In this example I would want to output
area peri shape perm
£4,990 2,791.90 0.09 6.30
£7,002 3,892.60 0.15 6.30
£7,558 3,930.66 0.18 6.30
£7,352 3,869.32 0.12 6.30
£7,943 3,948.54 0.12 17.10
£7,979 4,010.15 0.17 17.10
£9,333 4,345.75 0.19 17.10
£8,209 4,344.75 0.16 17.10
£8,393 3,682.04 0.20 119.00
£6,425 3,098.65 0.16 119.00
(With the header remaining bold and the bottom row also in bold, turns out stackoverflow is equally difficult to get in the format I want ;))