필터 지우기
필터 지우기

Surface fitting tool. What does center and scale do?

조회 수: 21 (최근 30일)
Imo
Imo 2012년 9월 4일
Hi everybody,
As the title says, I'm playing with surface fitting tool to create my surface using linear method. Can someone please explain to me what the option center and scale is doing to my graph. I have tried to do same thing with griddata function and I get the same result for my surface as I get using fitting tool but only when center and scale box is unchecked.
Thanks in advance.

채택된 답변

Tom Lane
Tom Lane 2012년 9월 5일
If you have the Statistics Toolbox, the following commands will reproduce the sftool results:
[X,Y,Z] = peaks;
x2fx([X(:) Y(:)],'q')\Z(:) % without centering/scaling
x2fx(zscore([X(:) Y(:)]),'q')\Z(:) % with centering scaling
The idea is that the x variable is replaced by (x-mean(x))/std(x) and the y variable is replace similarly. This is done before any polynomial terms are computed. The transformation won't change the fit theoretically, but it will make the results better conditioned on a computer with finite precision.
  댓글 수: 3
Tom Lane
Tom Lane 2012년 9월 6일
Can you tell me what type of fit you used? You mentioned linear in your original question. I assume that is linear interpolation?
Unfortunately we have stepped out of my area of expertise. I think this interpolant is based on a Delauney triangulation, and I would expect that to be affected by different scaling of the X and Y data. I don't know enough about the method or your data to have any intuition about whether one ought to be smoother or better than the other.
Imo
Imo 2012년 9월 7일
Yes linear interpolation, It be so. I'm acquiring Statistic toolbox in near future. Thanks Tom for the explanation, this is not my area of expertise either:)

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by