<div dir="ltr"><div class="gmail_default"><span style="color:rgb(7,55,99)">Hello,<br><br></span></div><div class="gmail_default"><span style="color:rgb(7,55,99)">I have a shapefile of a basin (irregular polygon) and I want to use it to clip a netcdf file (i.e, select only the points lying inside the shapefile).<br><br></span></div><div class="gmail_default"><span style="color:rgb(7,55,99)">There is an example that does the same on a 2d array however I have a variable with (time, lat, lon) coordinates for which this does not work;<br><br><a href="https://www.ncl.ucar.edu/Applications/Scripts/shapefiles_4.ncl">https://www.ncl.ucar.edu/Applications/Scripts/shapefiles_4.ncl</a><br><br></span></div><div><span style="color:rgb(7,55,99)">I am having a hard time modifying this to 3d. <div class="gmail_default" style="color:rgb(7,55,99);display:inline">Looping through all the time (thousands of values) is not feasible.</div><br><div class="gmail_default" style="color:rgb(7,55,99);display:inline">I</div>s it possible to mask the variable and output it as a separate netcdf or alternatively subset a</span><div class="gmail_default" style="display:inline"><span style="color:rgb(7,55,99)"> netcdf with irregular polygon.<br><br></span></div><div class="gmail_default" style="color:rgb(7,55,99);display:inline">Thanks<br></div><font size="2"><span style="font-family:courier new,monospace"><span style="color:rgb(153,153,153)">--<br></span></span></font></div><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div><div><div><div><font size="2"><span style="font-family:courier new,monospace"><span style="color:rgb(153,153,153)">Samar</span></span></font><br><div><div><br></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div>
</div>