Extrapolating from matrix data
조회 수: 3 (최근 30일)
이전 댓글 표시
I have a matrix that is 152 x 152:
Is there a way to extrapolte this matrix to 500 x 500 without getting the x-y-z data from it first?
Thanks,
Steve
댓글 수: 2
John D'Errico
2019년 3월 4일
Yes. But you might be foolish to extrapolate that far out. I'm not saying that people never do foolish things, but why add your name to the list? ;-)
My favorite quote about extrapolation cames from Mark Twain himself, in Life on the Mississippi (1884).
"In the space of one hundred and seventy six years the Lower Mississippi has shortened itself two hundred and forty-two miles. That is an average of a trifle over a mile and a third per year. Therefore, any calm person, who is not blind or idiotic, can see that in the Old Oölitic Silurian Period, just a million years ago next November, the Lower Mississippi was upwards of one million three hundred thousand miles long, and stuck out over the Gulf of Mexico like a fishing-pole. And by the same token any person can see that seven hundred and forty-two years from now the Lower Mississippi will be only a mile and three-quarters long, and Cairo [Illinois] and New Orleans will have joined their streets together and be plodding comfortably along under a single mayor and a mutual board of aldermen. There is something fascinating about science. One gets such wholesale returns of conjecture out of such a trifling investment of fact."
John D'Errico
2019년 3월 5일
편집: John D'Errico
2019년 3월 5일
@Steve: Please don't add an answer just to make a comment. Moved to a comment:
"Thanks for the diatribe.
I understand my application and the pitfalls associated with extrapolation.
Do you have an answer?
Thanks,
Steve"
답변 (1개)
John D'Errico
2019년 3월 5일
Sigh. Hint:
help interp2
help griddedInterpolant
Note that both allow you to extrapolate. I'm not sure what "getting the xyz data from it" means. You can't use a call to meshgrid to create x and y?
댓글 수: 2
Steven Lord
2019년 3월 5일
When you say ">50,000 XY pairs", are they on a grid (230-by-230 or thereabouts?) or are they scattered? If they're scattered, take a look at scatteredInterpolant.
참고 항목
카테고리
Help Center 및 File Exchange에서 Resizing and Reshaping Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!