# How to get the mathematical equation of a model trained using Regression learner toolbox

13 visualizaciones (últimos 30 días)
Sirish Selvam el 9 de Abr. de 2022
Respondida: Ravi el 21 de Dic. de 2023
I have created an SVM model using the regression learner. I have exported the trained model as well. How do I get the mathematical equation behind the model, that has all the coefficients and parameters that have been computed in the process of training?
##### 2 comentariosMostrar NingunoOcultar Ninguno
Ive J el 15 de Abr. de 2022
Not possible. The best you can get is the model object itself, and use predict method to predict over a new set of predictors.
Nathan Williams el 28 de Jul. de 2022
That is ridiculous. How is running a .m function preferable to executing a mathematical equation?

Iniciar sesión para comentar.

### Respuestas (1)

Ravi el 21 de Dic. de 2023
Hi Sirish Selvam,
I understand that you want to find the mathematical equation of the trained SVM model. Unfortunately, the mathematical equation of SVM is quite complex unlike the linear regression models.
There is no direct way to obtain the mathematical equation of the trained SVM, but you can still obtain the parameters, coefficients and bias term of the support vector machine model trained by accessing the model properties.
Let us assume the model trained is “svm_model”. We can access the support vectors, coefficients, and bias term as follows.
% Extract support vectors and coefficients
supportVectors = svm_model.SupportVectors;
coefficients = svm_model.Alpha;
% Extract bias term (if present)
bias = svm_model.Bias;
To learn more about the SVM model and its properties, please refer to the following link.
I hope this solution resolves the issue you are facing.
Thanks,
Ravi Chandra
##### 0 comentariosMostrar -2 comentarios más antiguosOcultar -2 comentarios más antiguos

Iniciar sesión para comentar.

### Categorías

Más información sobre Support Vector Machine Regression en Help Center y File Exchange.

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by