How to solve "Input values must be specified with a matrix of double or single values." error
2 次查看(过去 30 天)
显示 更早的评论
Good day! I created an anfis model to predict risk level and type of certain disease. For risk level (rfis) it has 19 inputs and for type (tfis) it has 5 inputs. Inputs are all in numeric type and came from the html ui. This is the code i made in matlab web app designer.
% Data changed function: Assessment
function AssessmentDataChanged(app, event)
data = event.Data;
rfis = readfis('riskFis.fis');
tfis = readfis('typeFis.fis');
riskInput = [data.Age data.Temp data.Lung data.Heart data.Diabetes data.HIV data.Cough data.Chemo data.Smoke data.Alcohol data.Chemical data.Swallow data.Sweating data.Breathe data.Chest data.Appetite data.Fatigue data.Nausea data.Confusion];
riskOutput = evalfis(rfis, riskInput);
typeInput = [data.Age data.Temp data.Cough data.Hospital data.Ventilator];
typeOutput = evalfis(tfis, typeInput);
disp(riskOutput)
disp(typeOutput)
end
And this is the error i get in command window whenever i run the code![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/800884/image.jpeg)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/800884/image.jpeg)
and this one is the error i received in matlab designer
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/800889/image.jpeg)
I hope someone can help me
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Fuzzy Logic Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!