BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi,

I have created a Propensity Model using Logistic Regression in Enterprise Miner 5.2.
The process has created a model based on the Training data set and when I use Score Node in the workflow I receive the Score Code. My question is, Is there a way we can implement the scoring in database programming language. ex: I have SQL SERVER 2005 database in which I have the full set of data on which I would like to apply the REGRESSION MODEL created in SAS enterprise Miner, How can I do that?

Thanks.
Jason.
4 REPLIES 4
LinusH
Tourmaline | Level 20
I don't believe that you could just convert Miner code to SQL Server SQL, not with a reasonable effort anyway. But I'm pretty sure that you could apply your model to SQL Server data through a SAS/ACCESS libname.

/Linus

PS
As seen on the web, SAS is creating modules that would make possible to run scoring models inside external RDBMS. Teradata is the first implementation (SAS Scoring Accelerator for Teradata). Haven't heard anything about a SQL Server implementation.
Data never sleeps
Doc_Duke
Rhodochrosite | Level 12
I think that you can apply it in SQL/Server, though I've not tried it.

The scoring just applies the logistic regression formula to the new data. The basic output of a binary logistic regression is
alpha + beta*x
where alpha is the intercept and the beta's are the regression coefficients.

If you want the risk probability for a new vector x', then the formula is

exp(alpha + beta*x')/(1 + exp(alpha + beta*x') )

where "exp(alpha + beta*x')" is the natural number "e" raised to the "alpha + beta*x'" power.
deleted_user
Not applicable
Thanks a lot.
After designing the workflow in ENTERPRISE MINER for logistic regression, I ran the workflow and got the score code.
Is alpha + beta*x value available in Score code script which is generated?
Is exp(alpha + beta*x')/(1 + exp(alpha + beta*x') ) the score value for each record?

I am new to SAS Enterprise Miner can you please help me out?

Thanks.
Jason.
Doc_Duke
Rhodochrosite | Level 12
I don't use enterprise miner, so I can't answer the specific questions. I know you get the outputs in PROC LOGISTIC in SAS/Stat. The score is either the alpha + beta*x (also known as the logit) or the predicted probability.

You may need to get a text and bone up on logistic regression or work with a statistician before you get too deep into this. At least read the chapter on logistic regression in the SAS/Stat manual.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 4 replies
  • 1162 views
  • 0 likes
  • 3 in conversation