Are these an unacceptable solutions to a SAS problem?
Seems to a lot of controversy about the relation between R and SAS.
A user wanted to convert excel to a csv
proc iml;
submit / R;
library(rio)
convert('d:xls/xls_sample.xlsx','d:xls/xls_sample.csv')
endsubmit;
quit;
or
%utl_submit_r64(
library(rio);
convert('d:xls/xls_sample.xlsx','d:xls/xls_sample.csv');
);
Hi @rogerjdeangelis,
I think people appreciate knowing about all options. Using SAS to call R functions for utilities like this can be handy for your toolbox, but most SAS users don't have R configured within their SAS environments. So when providing an answer in these forums, the suggestion to use SAS' integration methods with R is academic -- most people can't apply those techniques in their workplace. So a pure SAS answer is usually preferred, and is still the most relevant/helpful response that you can provide.
For this particular example, SAS has import/export utilities that can do similar work if you have SAS/ACCESS to PC Files (to read the Excel files). And if you don't have SAS/ACCESS but do have ability to call OS commands (required by R integration methods), then you can achieve the same by using VB Script or PowerShell or Python without needing a specialized R environment.
For people who do have R on their SAS environment, the main benefit is the ability to reuse R packages to experiment with methods that others have contributed to the R community, or perhaps to reuse work created by colleagues who use R primarily. See this demo and discussion from Rick:
https://www.youtube.com/watch?v=nmRQ3MtkG6A
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.