Hi SAS Community,
I am using SAS Studio in Viya and I am able to run python code in Jupyter using swat library of SAS. But now I wanted to execute Python scripts in SAS Studio.
Is there anyway through which I can execute python scripts in SAS studio in Viya ??
Thank You!
I'd love to hear more about your use case. We've kept SAS Studio focused on SAS coding. My assumption (based on talking to different types of users) is that a Python (or R or whatever) coder already has an interface they like using that's optimized for Python (or R, etc.). They would not consider using a SAS interface like Studio. So we made a conscious decision not to add support for other languages since it would take development effort away from the long wish list we have from SAS programmers. If that's not the case, I need to know! Thanks!
Actually In my case i am using SAS in Sas Studio and entire code in sas but somewhere in between in SAS code I need to execute python script to use one of python library in SAS studio.
Thank You!
What a minute!
Taking away the X command has an impact on far more tasks than running python or R, or any other language. I believe that it removes the ability to call any operating system command, no? So while many R and Python users may not miss the X command, I'm sure others will. I've often used X for other tasks - quickly getting directories, and other attributes of my files, and doing some housekeeping.
Possibly more awkward: doesn't taking away the X command also remove the ability to use a pipe in a filename statement? If so, then what if the user (user of unix in my case) wanted to use the TAIL command to get just the last 10 records of a 100 million record raw file, or quickly pipe in a list of a pattern-matching set of files in the directory via the LS plus grep command?
If these actually are the results of removing the X command in studio 5, I for one consider it a notable step backward. At least let access to the X command continued to be controlled by the system administrator.
Thanks for the use case (now documented in our requirements system). As for the ability to use X command, it's not a permanent removal from Studio. Studio 5.1 (which runs on SAS Viya) is a subset of Studio 3.x (running on 9.4) and the plan is for 5.x to get to replacement value of 3.x before we can release it on 9.4 (kind of confusing, I know, to have a higher release number with fewer functions). The goal is to have X command (and the rest) available and controllable by an administrator. We just don't yet have the microservices support in the 5.x world to implement it.
For being able to switch back and forth between languages, one option is to look at the interfaces like SAS Enterprise Miner in 9.4 or Model Studio in Viya. I'm not an expert on either, but I think they both support models in several languages in the same flow.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.