Change marker and hide confidence bounds in Plotting multiple linear regression (fitlm)
8 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I want to change marker for each plot and hide confidence bound
but I can not find related answer.
Where can I get a fitlm plotting properties?
Please help me :)
Thank you
X1 = R1.Research.TM_max_MFB(1,1:7) - R1.Research.P_max_MFB(1,1:7); X1 = X1*100;
Y1 = R1.Energy.bar(3,1:7); Y1 = Y1';
mdl1 = fitlm(X1,Y1);
mdl1summary = anova(mdl1,'summary');
X2 = R2.Research.TM_max_MFB(1,1:7) - R2.Research.P_max_MFB(1,1:7); X2 = X2*100;
Y2 = R2.Energy.bar(3,1:7); Y2 = Y2';
mdl2 = fitlm(X2,Y2);
mdl2summary = anova(mdl2,'summary');
X3 = R3.Research.TM_max_MFB(1,1:7) - R3.Research.P_max_MFB(1,1:7); X3 = X3*100;
Y3 = R3.Energy.bar(3,1:7); Y3 = Y3';
mdl3 = fitlm(X3,Y3);
mdl3summary = anova(mdl3,'summary');
figure(1); grid on ; hold on
plot(mdl1);
plot(mdl2);
plot(mdl3);
legend('Adjusted data','Linear ployfit ')
xlabel('MFB_Pmax - MFB_TMmax [%]')
ylabel('Exhaust Energy [%]')

0 commentaires
Réponse acceptée
Chunru
le 29 Août 2022
load carsmall
X = [Weight,Horsepower,Acceleration];
% Fit a linear regression model by using fitlm.
mdl = fitlm(X,MPG);
% use handle for plotting
h = plot(mdl)
h(1).Marker = 's' % change marker
delete(h(3)) % delete bounds
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Linear and Nonlinear Regression 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!
