Hi all,
I've been using the wdTable() function from R2wd package and it's been working great. However I just tried to do the following: > table.2 Waste Rebate code Chargeable (fin_map) Quantity (qty) Total [1,] "Waste" "Rebate code" "CHG" "121" "$22,534.01" [2,] "Waste" "Rebate code" "NOCHG" "229" "$51,346.14" [3,] "Waste" "No code" "CHG" "2" "$1,260.01" [4,] "Waste" "No code" "NOCHG" "26" "$10,969.1" [5,] "Total Waste" "" "" "378" "$86,109.26" [6,] "No Waste" "Rebate code" "CHG" "5,330" "$3,427,721" [7,] "No Waste" "Rebate code" "NOCHG" "15,781" "$6,949,667" [8,] "No Waste" "No code" "CHG" "197" "$143,407.2" [9,] "No Waste" "No code" "NOCHG" "1,205" "$1,172,939" [10,] "Total No Waste" "" "" "22513" "$11,693,735" [11,] "Grand Total" "" "" "22891" "$11,779,844" Per cent Total $ [1,] "0.2%" [2,] "0.4%" [3,] "0%" [4,] "0.1%" [5,] "0.7%" [6,] "29.1%" [7,] "58.9%" [8,] "1.2%" [9,] "9.9%" [10,] "99.2%" [11,] "99.9%" > format(table.2) Waste Rebate code Chargeable (fin_map) Quantity (qty) [1,] "Waste " "Rebate code " "CHG " "121 " [2,] "Waste " "Rebate code " "NOCHG " "229 " [3,] "Waste " "No code " "CHG " "2 " [4,] "Waste " "No code " "NOCHG " "26 " [5,] "Total Waste " " " " " "378 " [6,] "No Waste " "Rebate code " "CHG " "5,330 " [7,] "No Waste " "Rebate code " "NOCHG " "15,781 " [8,] "No Waste " "No code " "CHG " "197 " [9,] "No Waste " "No code " "NOCHG " "1,205 " [10,] "Total No Waste" " " " " "22513 " [11,] "Grand Total " " " " " "22891 " Total Per cent Total $ [1,] "$22,534.01 " "0.2% " [2,] "$51,346.14 " "0.4% " [3,] "$1,260.01 " "0% " [4,] "$10,969.1 " "0.1% " [5,] "$86,109.26 " "0.7% " [6,] "$3,427,721 " "29.1% " [7,] "$6,949,667 " "58.9% " [8,] "$143,407.2 " "1.2% " [9,] "$1,172,939 " "9.9% " [10,] "$11,693,735 " "99.2% " [11,] "$11,779,844 " "99.9% " > wdTable(format(table.2), caption = "Wastage by chargeable status and rebate code") Error in out[1 + (1:nr), 1] <- row.names(data) : number of items to replace is not a multiple of replacement length I'm not sure what caused the error message (table.2 can be exported as a CSV file fine), and am wondering if anyone has experience similar problem using wdTable()? Kind regards Kevin Wang Manager, Government Advisory Services Advisory KPMG 10 Shelley Street Sydney NSW 2000 Australia Tel +61 2 9335 8282 Fax +61 2 9335 7001 Mob 0419 374 580 kevinw...@kpmg.com.au <mailto:kevinw...@kpmg.com.au> kpmg.com.au <http://kpmg.com.au> Protect the environment: please think before you print [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.