Forum Discussion
Why doesn't Power BI recognize my R output as an excel document?
wouldn't that be more of a question for the maintainers of the openxlsx package? Maybe they save in .xls format and only slap a .xlsx extension on in the hope nobody notices.
Another question would be why you involve that package in the first place. It would likely be more performant if you dump the dataframe into a CSV file and then consume that in Power BI.
An R script can do more than just prepare data to be loaded into PBI. It isn't only another way of cleaning code like M. It can also write the data out. So in an example where this can be very beneficial is to write an R script to pull data in, clean it, and save a portion to a folder as an excel file. Then continue cleaning data and preparing it for PBI. Either more data sets or still working with the one that was saved out.
This R script then can be ran within PBI, and scheduled out.
This can be done now, but can NOT save out as Parquet or Excel since both the Arrow Package or the Openxlsx Package at this time are NOT supported by R packages within PBI.