필터 지우기
필터 지우기

How to use least square fit to 2D matrix data

조회 수: 11 (최근 30일)
Luis Jesús Olvera Lazcano
Luis Jesús Olvera Lazcano 2023년 9월 7일
I have a set of OLR data in longitude x time, giving a size of 180 x 31, being xaxis the longitude and y-axis lag time in days. How would you measure the phase propagation of the minimum values (in contour), starting at the minimum on day 0?
I know it has to do with a least square fit, but I dont know how to do it

답변 (1개)

Matt J
Matt J 2023년 9월 7일
[~,location]=min(Data);
  댓글 수: 3
Matt J
Matt J 2023년 9월 7일
If you mean you want to do a line fit to the minima locations, then,
[~,location]=min(Data);
p=polyfit(0:30,location,1);
slope=p(1);
Luis Jesús Olvera Lazcano
Luis Jesús Olvera Lazcano 2023년 9월 7일
Ohhh, but how do i put it in the same pcolor graph?
Im sorry Im a little lost with this, but thanks youre helping me a lot

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Linear and Nonlinear Regression에 대해 자세히 알아보기

제품


릴리스

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by