How to get rid of lsline in regression plot?

조회 수: 2 (최근 30일)
Rita
Rita 2016년 4월 15일
답변: Ced 2016년 4월 15일
I have a regression plot with a blue lsline which I want to eliminate it but I don't know how.Thanks for any suggestion.

채택된 답변

Ced
Ced 2016년 4월 15일
N = 15;
x = linspace(0,5,N)';
y = 1.3*x + 0.5*randn(N,1);
% 0. plot data and lsline
plot(x,y,'o')
lsline
% 1. find handle to lsline
h_lsline = findobj(get(gca,'Children'),'Tag','lsline');
% 2. switch off, i.e. remove lsline
set(h_lsline,'Visible','off');
Cheers

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Scatter Plots에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by