how to specify points outside a polygon?

4 次查看(过去 30 天)
For example, in the below code, I can specify the points inside the polygon. How about outside the polygon? How do I specify that?
IN = inpolygon(lon, lat, x0, y0);
lon = lon(IN);
lat = lat(IN);
ph1 = ph1(IN);

采纳的回答

Walter Roberson
Walter Roberson 2018-5-8
IN = inpolygon(lon, lat, x0, y0);
lon = lon(~IN);
lat = lat(~IN);
ph1 = ph1(~IN);

更多回答(1 个)

Leon
Leon 2018-5-8
Many thanks for the help!

标签

产品

Community Treasure Hunt

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

Start Hunting!

Translated by