<div dir="ltr">Dear NCL,<div><br></div><div>I am using the following NCL code to read a shapefile attribute table (which allows further computation), but when I printed out all the "COMIDs", they are all "0". But when I open the shapefile in ArcGIS, the COMIDs can be correctly shown. Can anybody provide some hints to resolve this? </div>
<div><br></div><div><b>begin<br></b></div><div>
<p class=""><b>shp_file = "./NHDFlowline.shp"</b></p>
<p class=""><b>f = addfile(shp_file,"r")</b></p>
<p class=""><b>varnames = getfilevarnames(f)</b></p>
<p class=""><b>print("varnames = "+varnames)</b></p>
<p class=""><b>COMIDs = f->COMID</b></p>
<p class=""><b>print(COMIDs)</b></p>
<p class=""><b>end</b></p></div><div><br></div><div>I've already made sure the COMID is a variable in the shapefile, but the values just cannot be read correctly. Thank you in advance for replying!!</div><div><br></div>
<div>Best,</div><div>Peirong</div><div><br clear="all"><div><br></div>-- <br><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><div style="color:rgb(255,102,0)"><b>Peirong Lin</b> (Ms.)<br>
Graduate Research Assistant <span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse;color:rgb(204,102,0)">(JGB 5.322)</span></span><br>
Jackson School of Geosciences</div><div><font color="#ff6600">The University of Texas at Austin</font><br><font color="#ff6600">Contact: 512-201-3731 </font><br><a href="mailto:prlin@utexas.edu" style="color:rgb(255,102,0)" target="_blank">prlin@utexas.edu</a><font color="#ff6600">; </font><a href="mailto:peironglinlin@gmail.com" style="color:rgb(255,102,0)" target="_blank">peironglinlin@gmail.com</a><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse"></span></div>
</span>
</div></div>