BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
Kiteulf
Quartz | Level 8

 

 

Hi

 

Does anyone know the sourcecode for the function compged? 

I will be utilizing this function in another system that doesn't support that sas function.

1 ACCEPTED SOLUTION

Accepted Solutions
Ksharp
Super User
Emmm. You could do it ,but you need pay some money to sas ,like buy SAS/Viya(run a service like JSON ) or SAS/Base .(run a batch file to invoke COMPGEND function )
If you want free(open source) stuff ,try Python .

View solution in original post

12 REPLIES 12
PeterClemmensen
Tourmaline | Level 20

SAS does not usually share source code for its functions. What system do you want to use it in? There is probably a function available that will return the same result?

Ksharp
Super User
Check sas documentation about compged() ,especially in DETAILS , maybe you could find some clue.
Kiteulf
Quartz | Level 8

 

Yeah there are some clues, but I wish someone had a script doing the compged . 

 

It is to be used in a decision engine.

Ksharp
Super User
As @PeterClemmensen said, Maybe you could find some similar function in R or Python ?
Kiteulf
Quartz | Level 8

 

Yes if anyone could point me in the right direction... I have spent days searching and I can't find anything. 

 

So the lessons is don't use SAS functions when developing stuff??? or better, use python for every step.... 😞

ChrisNZ
Tourmaline | Level 20

No the lesson is that SAS put a lot of expertise in its 1000-odd functions and make a living by selling that expertise.

As you discover, this expertise is real and not always widely spread or available.

While FOSS is incredibly useful, not all good things in life come free.

Kiteulf
Quartz | Level 8

If there no one except sas fanboys here that can point to where the similar code is in python or r, I guess I will have to rewrite the setup to get rid of the sas stuff.
ChrisNZ
Tourmaline | Level 20

> If there no one except sas fanboys here that can point to where the similar code is in python or r,

One tends to find people knowledgeable about SAS on SAS forums, and people knowledgeable about python on python forums.

 

>I will have to rewrite the setup to get rid of the sas stuff.

If your overriding priority is to have absolutely everything free, then yes.

 

 

Kiteulf
Quartz | Level 8
We pay SAS millions every year but it boils down to pay even more.


ChrisNZ
Tourmaline | Level 20

You have a massive site if you pay that much. And if you do, you have access to all the compged goodness, and much more.

Just like if you lease a car, you can use all the features, but you don't buy the manufacturer's IP.

I am not even sure what the discussion is about actually. 

Ksharp
Super User
Emmm. You could do it ,but you need pay some money to sas ,like buy SAS/Viya(run a service like JSON ) or SAS/Base .(run a batch file to invoke COMPGEND function )
If you want free(open source) stuff ,try Python .
Dev22
Calcite | Level 5
How get batch file to invoke COMPGEND function

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 12 replies
  • 3406 views
  • 0 likes
  • 5 in conversation