I have a small dataframe of dimension 2 x 8
(see below) and I'd like to create a simple white table with the row names "scenario 1" and "scenario 2".
How can I do this as simple as possible? Could someone also show me how to swap the order of the columns?
dput
:
structure(list(A = list(0.934842767295597, 0.92922841571852),
B = list(0.516589250165893, 0.525067529460655), C = list(
0.867615330138182, 0.866211826128489), D = list(0.0881670095698295,
0.0834131044726853), E = list(0.85734568558549, 0.856776377557092),
F = list(1.02523463957426, 1.01379194951716), G = list(0.444709565304963,
0.419220178831526), H = c(0.22, 0.25)), row.names = c(18L,
21L), class = "data.frame")
Thank you!
EDIT: The output should be a table with 16 values (2x8). The column 'H' should be on the left. The first row label should be 'scenario 1' and the second row label should be 'scenario 2' (these labels are currently not included in my example). The values should be rounded to two decimals. I do not want to create a fancy table, but rather a simple table that can be saved as a pdf.