フィルターのクリア

How to save a plot with multiple overlays as a single variable and/or plot the regression for all points as one line?

2 ビュー (過去 30 日間)
I have multiple samples in each graph that i have overlahyed using the hold on function, i am looking to find the regression for all points on the final overlayed scatter plot!
hold off
t = tiledlayout(1,2)
ax1 = nexttile
%Cre+
hold on
scatter(t1.D,t1.CC)
scatter(t6.D,t6.CC)
scatter(t8.D,t8.CC)
scatter(t9.D,t9.CC)
scatter(t12.D,t12.CC)
xlim([0 1000])
ylim([250 6000])
title('Cre-')
ylabel('Area(pixels^2)')
xlabel('Distance from nearest Sinus edge (pixels x 10^3)');
ax2 = nexttile
% Cre-
hold on
scatter(t4.D,t4.CC)
scatter(t5.D,t5.CC)
scatter(t10.D,t10.CC)
scatter(t11.D,t11.CC)
scatter(t13.D,t13.CC)
xlim([0 1000])
ylim([250 6000])
title('Cre-')
ylabel('Area(pixels^2)')
xlabel('Distance from nearest Sinus edge (pixels x 10^3)');
Thanks!

回答 (1 件)

KSSV
KSSV 2021 年 7 月 22 日
Read about function regression to get the regression value and read about plotregression to get the regression plot.
  2 件のコメント
Theodore Fisher
Theodore Fisher 2021 年 7 月 22 日
this seems to apply to only one plot at a time, i am looking to apply accross all points
KSSV
KSSV 2021 年 7 月 22 日
Calculate the value using regression and use scatter to plot.

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeScatter Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by