Building models with SAS Enterprise Miner, SAS Factory Miner, SAS Visual Data Mining and Machine Learning or just with programming

Calculation of the Probabilities from Scores of Decision Tree

Reply
Occasional Contributor
Posts: 12

Calculation of the Probabilities from Scores of Decision Tree

Dear All,

 

After I have created a Decesion Tree Model, kindlly i need your help to advice me how can I convert the Score I optained from the Variable P_target_1 in to Probabilites . Please note that I haven't used Deceison Node . Is that avaiable ?

 

All I have right now is the Score of Prediction and a Flag for the real event (1/0) 

 

P.S : I have reviesed the below link  (https://communities.sas.com/t5/SAS-Data-Mining/Adjusted-Prior-in-Enterprise-Miner-7-1-Please-help-Th...) for a simmilar enquiry but couldn't find a solution to my particular case.

 

 

Thanks and Best Regards,

Mohammed ElSofany

Data Scientist .

Super User
Posts: 17,959

Re: Calculation of the Probabilities from Scores of Decision Tree

What do you mean by probability? Probability of being a 0/1? I don't think that's how a decision tree process works. It's a rule based algorithm, not probabilistic. 

Occasional Contributor
Posts: 12

Re: Calculation of the Probabilities from Scores of Decision Tree

Dear Reeza,

Thanks for your reply . Normaly DT is not Probabilistic . But what if I want to extract from the Score produced a Probability of the event to happen (to be 1 not 0 ) .

 

Thanks 

Super User
Posts: 17,959

Re: Calculation of the Probabilities from Scores of Decision Tree

I'm trying to think how that would work and it would be equivalent to the prior probability of 0/1 is my guess. 

If you need a probability why not fit a different model type, ie logistic regression? 

 

If you fit multiple trees with differing rules then perhaps an average of outcomes could be determined to extract a probability. So a simulation type analysis. 

Super User
Posts: 17,959

Re: Calculation of the Probabilities from Scores of Decision Tree

I think your looking for the conditional probability of the end points/nodes. Does that sound correct? 

Similar to this?

http://petrowiki.org/Decision_tree_analysis

Occasional Contributor
Posts: 12

Re: Calculation of the Probabilities from Scores of Decision Tree

As a matter of fact that's simmilar to what I'm reading now : )

 

 

https://www.microsoft.com/en-us/research/wp-content/uploads/2016/02/decisionForests_MSR_TR_2011_114....

 

Thanks !

Mohammed ElSofany

Occasional Contributor
Posts: 12

Re: Calculation of the Probabilities from Scores of Decision Tree

In a matter of fact I still can't get it from the both links .

 

All I am looking for is to get the Probability using the Score and using overall Probabilty of event occure gained from trainning data or cross validation data.

 

VBR

Super User
Posts: 17,959

Re: Calculation of the Probabilities from Scores of Decision Tree

Is your issue technical, ie how to calculate a specific value, or methodological - how do I calculate the probabilities. 

 

Please take the time to explain your question in as much detail as possible. Especially if its a calculation question.

Occasional Contributor
Posts: 12

Re: Calculation of the Probabilities from Scores of Decision Tree

Dear Reeza,

Thank you for all the message very much!

 

Yes It's a calculation ,

I have built a Decesion Trees Model with Binary Classification.

To build this model I have used Oversampling approach .

I have't used any Decesion Nodes ( Before Model or After Model )

I want to get the Probability of occurnace of the event from the P_target_1

P_target_1 is not probability it's Model Score .

I need to have the Probability .

 

I hope I was clear enough,

 

Thanks and best regards,

Mohammed ElSofany

SAS Employee
Posts: 106

Re: Calculation of the Probabilities from Scores of Decision Tree

For a decision tree built using a nominal or binary target, the P_ variables are the posterior probabilities (given a set of input values, what is the predicted probability of a particular outcome) for each possible outcome.

 

So you probably already have what you are looking for.

 

Here's a detailed reference:

 

Meaning of score output variables

Occasional Contributor
Posts: 12

Re: Calculation of the Probabilities from Scores of Decision Tree

Thanks Rally for your reply ,

Is this can be applied even if I didn't use Decesion Node and I have used Oversampling ?

 

Regards,

Ask a Question
Discussion stats
  • 10 replies
  • 568 views
  • 1 like
  • 3 in conversation