Spyke

Syndicated from the fediverse. Read and engage on the original instance.

View original on lemmy.world

print to console tables that can be easily copied and pasted to Excel

There is a function format_csv in package readr, which outputs csv formated output to string. It can be used as

to_console<-function(dta){
 cat(readr::format_csv(dta))
}


dta |> someoperation() |> to_console()
View original on lemmy.world
13

2 replies

lemmy.world

I use clipr::write_clip and clipr::read_clip - can paste to excel but also read in something you've copied from excel.

Helpful when you have a client with poorly formatted excel files, to the point that readxl won't do the job 😭

4

Seconding clipr, it's my go-to for when i just need to quickly check or transferring something to and from Excel.

2

You reached the end

print to console tables that can be easily copied and pasted to Excel | Spyke