Clear Filters
Clear Filters

How to plot a surf-plot without data extrapoation?

4 views (last 30 days)
I would like to plot the same surf plot but without extrapolating on areas where are not scatter data.
The following script generates the attached figure.
The final plot should interpolate below the black line (only where data exists) like:
  3 Comments
Philippe Corner
Philippe Corner on 3 Dec 2020
Edited: Philippe Corner on 3 Dec 2020
Hi Star Strider, thanks for your help. I edited de question to clarify what I'm trying to do
Philippe Corner
Philippe Corner on 6 Dec 2020
Hi Star Strider.. any idea about how to solve? if you are thinking on anything i'm sure it would be helpfull

Sign in to comment.

Accepted Answer

KSSV
KSSV on 4 Dec 2020
You have the black line in hand.. make a closed polygon out of it and get the indices of the points lying inside and outside using inpolygon. From the data matrix, make the points lying outside NaN.
  6 Comments

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!