How can one fuzzify a Support Vector Regression (SVR) model?

7 vues (au cours des 30 derniers jours)
nastaran moosavi
nastaran moosavi le 25 Nov 2020
Dear all,
I have a SVR model. I want to fuzzify it. I mean I want to fuzzify this model and change it to a 'Fuzzy SVR' system. Could anyone help me how I can do it?
Many Thanks,

Réponses (1)

Sam Chak
Sam Chak le 24 Avr 2025
If the data from the Support Vector Regression (SVR) model is available, it is possible to train an Adaptive Neuro-Fuzzy Inference System (ANFIS) model.
%% SVR data
x = linspace(-1, 1, 2001)';
y = asinh(50*x);
mdl = fitrsvm(x, y, 'Standardize', true, 'KernelFunction', 'gaussian', 'KernelScale', 'auto');
yfit= predict(mdl, x);
figure
plot(x, yfit), grid on
xlabel('Input'), ylabel('Output'), title('Data from SVR')
%% create initial FIS
genOpt = genfisOptions('GridPartition');
genOpt.NumMembershipFunctions = 4;
genOpt.InputMembershipFunctionType = 'gauss2mf';
genOpt.OutputMembershipFunctionType = 'constant';
inFIS = genfis(x, yfit, genOpt);
%% train ANFIS
opt = anfisOptions('InitialFIS', inFIS, 'EpochNumber', 50);
opt.DisplayANFISInformation = 0;
opt.DisplayErrorValues = 0;
opt.DisplayStepSize = 0;
opt.DisplayFinalResults = 0;
outFIS = anfis([x yfit],opt);
figure
plotrule(outFIS)
%% plot result
figure
plot(x, [yfit, evalfis(outFIS, x)]), grid on
xlabel('Input'), ylabel('Output'),
title('Compare SVR Data with Trained ANFIS Output')
legend('SVR Data', 'Trained ANFIS Output', 'location', 'southeast')

Catégories

En savoir plus sur Fuzzy Logic Toolbox dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by