Changeset 25455 for issm/trunk-jpl/src/m/classes/basin.m
- Timestamp:
- 08/25/20 00:32:13 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/classes/basin.m
r25065 r25455 117 117 %recover options 118 118 options=pairoptions(varargin{:}); 119 x=[]; y=[]; 119 x=[]; 120 y=[]; 120 121 121 122 %go through boundaries, recover edges and project them in the basin epsg reference frame: … … 127 128 y=[y;contour.y]; 128 129 end 130 129 131 %close the contour: 130 132 if x(end)~=x(1) | y(end)~=y(1), … … 181 183 error('Basin shapefilecrop error message: epsgshapefile or projshapefile should be specified'); 182 184 end 183 184 185 185 186 %create list of contours that have critical length > threshold (in lat,long): … … 209 210 for i=1:length(contours), 210 211 h=contours(i); 211 isin=inpolygon(h.x,h.y,ba.x,ba.y); 212 isin=inpolygon(h.x,h.y,ba.x,ba.y); 212 213 if ~isempty(find(isin==0)), 213 214 flags(i)=1; 214 215 end 215 216 end 216 pos=find(flags); contours(pos)=[]; 217 218 pos=find(flags); 219 contours(pos)=[]; 217 220 218 221 %Two options:
Note:
See TracChangeset
for help on using the changeset viewer.