Effacer les filtres
Effacer les filtres

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

2 vues (au cours des 30 derniers jours)
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!

Réponses (1)

KSSV
KSSV le 22 Juil 2021
Read about function regression to get the regression value and read about plotregression to get the regression plot.
  2 commentaires
Theodore Fisher
Theodore Fisher le 22 Juil 2021
this seems to apply to only one plot at a time, i am looking to apply accross all points
KSSV
KSSV le 22 Juil 2021
Calculate the value using regression and use scatter to plot.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Scatter Plots 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!

Translated by