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

Multi Classes SVM

Accepted Solution Solved
Reply
Contributor
Posts: 43
Accepted Solution

Multi Classes SVM

Dear Members;

How to implement multi target svm in SAS Enterprise Miner 13.2?

I know the HPSVM is implemented for binary classification? Is there found any method to implement it now?

Regards


Accepted Solutions
Solution
‎07-15-2015 05:03 PM
SAS Employee
Posts: 15

Re: Multi Classes SVM

Posted in reply to husseinmazaar

Currently in enterprise miner the SVM node can only handle binary classification.

With a bit of work, you can get multi class SVM working. Here are the steps:

1) Create a new column for each level of the target. For column1, each observation should have a value of 1 if the target is level1 or 0 otherwise. For column2 each observation should have a value of 1 if the target is level2 or 0 otherwise. Repeat this for each level of the target.

2) Run a number of SVM models equal to the number of levels of the target. For each SVM model, specify the target as one of the newly created columns. You're using each created column as a binary target, and by creating an SVM model for each, you then have covered all of the levels of the target variable.

3) For the SVM model built on level1 you will get a probability that the target is level1, for the SVM model built on level2 you will get a probability that the target is level2, and so on. Choose the largest probability, and the level of the target associated with it.

4) For scoring new data, you score an observation using each model. Pick the level with the highest probability assigned to it from among all the models.

I hope this helps give some guidance.

View solution in original post


All Replies
Solution
‎07-15-2015 05:03 PM
SAS Employee
Posts: 15

Re: Multi Classes SVM

Posted in reply to husseinmazaar

Currently in enterprise miner the SVM node can only handle binary classification.

With a bit of work, you can get multi class SVM working. Here are the steps:

1) Create a new column for each level of the target. For column1, each observation should have a value of 1 if the target is level1 or 0 otherwise. For column2 each observation should have a value of 1 if the target is level2 or 0 otherwise. Repeat this for each level of the target.

2) Run a number of SVM models equal to the number of levels of the target. For each SVM model, specify the target as one of the newly created columns. You're using each created column as a binary target, and by creating an SVM model for each, you then have covered all of the levels of the target variable.

3) For the SVM model built on level1 you will get a probability that the target is level1, for the SVM model built on level2 you will get a probability that the target is level2, and so on. Choose the largest probability, and the level of the target associated with it.

4) For scoring new data, you score an observation using each model. Pick the level with the highest probability assigned to it from among all the models.

I hope this helps give some guidance.

Contributor
Posts: 43

Re: Multi Classes SVM

Posted in reply to husseinmazaar

Dear Ralph

Thanks so much, your comments have helped me more .

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 2 replies
  • 944 views
  • 0 likes
  • 2 in conversation