BookmarkSubscribeRSS Feed
rogerjdeangelis
Barite | Level 11
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'); );
1 REPLY 1
ChrisHemedinger
Community Manager

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 time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 536 views
  • 2 likes
  • 2 in conversation