# How to fill the gaps in a patch plot through adaptive interpolation

1 ビュー (過去 30 日間)
AAS 2020 年 9 月 3 日
コメント済み: AAS 2020 年 9 月 4 日
I have a 2 dimensional patch plot that looks like this where the colors represent magnitude of flow rate so basically I have x position, y position and magnitude of flow rate for each of the patches you see.
Is there any way I can fill in the entire area (within the red lines in the below image )through some sort of adaptive interpolation of particular connectivity so it does not fill up the entire image?

#### 7 件のコメント

AAS 2020 年 9 月 3 日
Hi Alex,
I basically want to do some sort of adaptive interpolation for each point you see. The color of the point defines the magnitude. So I want to do some sort of interpolation through connectivity. For example, for each point, create 8 more points around it with same magnitude. I tried griddata and scatteredinterpolant @KSSV but the white space gets filled due to some errors with the convex hull. Do you have any other recommendations?
J. Alex Lee 2020 年 9 月 3 日
so you are not asking to fill in the space between the red curves with a single color, but you want the region between the red curves to be a patchwork of color, informed by the small patches you already have in there?
AAS 2020 年 9 月 3 日
Yes exactly

サインインしてコメントする。

### 回答 (2 件)

J. Alex Lee 2020 年 9 月 3 日
You could add in "corners" where your red curves intersect the y-axes as new (x,y) coordinates, then do a convexhull on them. That should create a "tight" blanket around your points.
If you can then identify those points along the top edge vs bottom edge (in this case maybe above and below mean y-value?) you can shift or stretch the appropriate y-coordinates up and down appropriately.
Could it work?

#### 2 件のコメント

J. Alex Lee 2020 年 9 月 4 日
edit: this answer is for drawing a single colored band indicated by something like the red curves in the question, it does not answer the actual question.
AAS 2020 年 9 月 4 日
No I am sorry that’s not what I am looking for but thanks for the suggestion.

サインインしてコメントする。

J. Alex Lee 2020 年 9 月 4 日
If you reduce your current patches into single (x,y) coordinates, e.g., center of mass, then you can triangulate/find the voronoi diagram of them
And hopefully be able to use that as a basis to create the patches you are looking for

サインインしてコメントする。

### Community Treasure Hunt

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

Start Hunting!

Translated by