Color inside Confidence Interval after a fitlm
Hi
I’d like to color the area in betwen the Confidence Interval after a fitlm, like shown in the attached pic
I tried patch, area, fill, but I couln’t make any of them work.
I think the issue is that the x values are not continuous (it’s not 1:19 for example)
I have 2 continuous variables
% x = rand(1,19); y = x+[1:19];
d = load(‘d.txt’) ;
x = d(:,1) ;
y = d(:,2) ;
mdl = fitlm(x,y)
mdl.plot
thanks a lotHi
I’d like to color the area in betwen the Confidence Interval after a fitlm, like shown in the attached pic
I tried patch, area, fill, but I couln’t make any of them work.
I think the issue is that the x values are not continuous (it’s not 1:19 for example)
I have 2 continuous variables
% x = rand(1,19); y = x+[1:19];
d = load(‘d.txt’) ;
x = d(:,1) ;
y = d(:,2) ;
mdl = fitlm(x,y)
mdl.plot
thanks a lot Hi
I’d like to color the area in betwen the Confidence Interval after a fitlm, like shown in the attached pic
I tried patch, area, fill, but I couln’t make any of them work.
I think the issue is that the x values are not continuous (it’s not 1:19 for example)
I have 2 continuous variables
% x = rand(1,19); y = x+[1:19];
d = load(‘d.txt’) ;
x = d(:,1) ;
y = d(:,2) ;
mdl = fitlm(x,y)
mdl.plot
thanks a lot area color, fitlm, confidence interval MATLAB Answers — New Questions









