Manipulating Data in Base SAS® Part 3 – Deduplicate
Recent Library Articles
Recently in the SAS Community Library: Duplicates in data can badly skew the results of an analysis. @SASJedi demonstrates data deduplication using PROC SORT with the NODUPKEY, OUT=, and DUPOUT= options and PROC SQL and PROC FedSQL
Hi,
Can some one help me to dsiplay report like below .
I am looking for Regular Page Number , BY variable page number on same line (left,,right)
Page number : 1 Byvariable:State:MN : Page No :1
Page number : 2 Byvariable:State:MN : Page No :2
Page number : 3 Byvariable:State:MN : Page No : 3
====================
Page number : 4 Byvariable:State:OH : Page No :1
Page number : 5 Byvariable:State:OH : Page No :2
Page number : 6 Byvariable:State:OH : Page No : 3
Thanks
... View more
Imagine this – you’re in the thick of your semester projects, and you discover SAS Viya for Learners 4, a cloud-based analytics software provided free to students and educators who register with an academic email address. Oh, the realm of possibilities at your fingertips! Your excitement cannot be contained. You have to reach out to your buddy, who will certainly be as excited as you...
Pinch yourself – it’s not a dream!
In SAS Studio, tapping into open-source coding capabilities has never been easier. Whether you’re a Python enthusiast or a dedicated R coder, SAS Viya for Learners 4 has you covered!
How to Access These Features:
1. Pure Python Script: If your task can be accomplished entirely with Python, no need to mix SAS and Python syntax! Keep your code clean and straightforward by using a Python script.
From the Editor Window, simply click the + icon in the Editor window to start a new Python program.
Alternatively, click the New button in the top pane and select Python program to create a fresh Python script.
Through either method, your script is fully equipped to handle your Python code seamlessly. This method also opens the door to uploading your .PY scripts to SAS Studio so you can continue any previous analyses smoothly!
2. Harnessing Python with PROC Python: Expand your capabilities by incorporating Python code directly into your SAS workflows using PROC Python. This powerful procedure allows you to run Python scripts within your SAS environment, combining the best of both worlds for a truly integrated analytics experience. If you want to learn more about this, check out @NicolasRobert's post Using PROC PYTHON to augment your SAS programs.
3. Calling All R Coders: Exciting news for R users! With the latest updates in Viya for Learners 4, you can now execute R code within PROC IML. This integration provides a robust platform for your statistical and mathematical computations, leveraging the full power of R within SAS.
TL;DR Version:
There are three ways to utilize Python and R from within SAS Studio on SAS Viya for Learners 4!
Python Program: Start a new Python script via the + in the Editor window or the New button in the top pane.
PROC Python: Utilize Python code seamlessly within your SAS workflows using the PROC Python procedure.
PROC IML for R: Call your R code from within PROC IML to harness the advanced statistical capabilities of R in your SAS environment.
Why Wait? Get Started Today! Explore the enhanced capabilities of Viya for Learners 4 and elevate your data analysis with seamless open-source integrations. Whether you’re scripting in Python or coding in R, SAS Studio makes it easy to bring your projects to life.
... View more
How can I increase the precision of the GINI calculation when running the model performance monitoring in SAS Model Manager on SAS Viya? I see that due to how the GINI calculation is implemented in SAS Model Manager, this calculation can deviate quite a bit from the true GINI of a model when calculated via proc logistics. I work with probability of default models and these models tend to have very narrow ranges for the predicted PD's. This causes the model monitoring to underestimate the performance of the model, presumably due to how the calculation is performed with too little granularity in setting the cut-offs to be evaluated.
... View more
How do I create CAS tables with a table name containing the ModelUUID in the name? From the documentation of SAS Model Manager under Monitoring Performance the following naming conventions are listed for input tables to the monitoring performance job: Supported Formats Use one of the following formats for the name of the data tables: prefix_sequenceNumber_timeLabel prefix_sequenceNumber_timeLabel_modelUUID prefix_sequenceNumber_timeLabel_modelUUID_modelRole Further the documentation states: The model UUID is the fourth level of the table name. If you provide user-scored data and select a library to use for performance monitoring, the data table names must contain the UUID of the model. How can this be accomplished when the modelUUID contains hyphens that are not supported through SAS Naming Conventions?
... View more