0

I am trying to make descriptive statistics table using the basicStats function from fBasics library. Code is as follows.

sum_desc_stat=basicStats(sum_stat)
sum_desc_stat
write_xlsx(sum_desc_stat,'C:/Users/sum_desc_stat.xlsx')

If I run this in R, it shows me the names of the rows like Nobs, Mean, SD, etc. However, if I save that as Excel file, I can't see any of the rownames.
Can anyone help me how to display the rownames in Excel file as well?

Dave2e
  • 22,192
  • 18
  • 42
  • 50
J L
  • 13
  • 4
  • It would be helpful if you shared a [reproducible example](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example). – Desmond May 28 '21 at 12:40
  • See if `tibble::rownames_to_column()` function solves your problem. – Dave2e May 28 '21 at 12:50

0 Answers0