why has one of the attribute names been changed by MATLAB when using the shaperead function to read a point shp file?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Songqiu
am 17 Apr. 2018
Bearbeitet: Songqiu
am 18 Apr. 2018
I have a point shp file 'ULS170527All.shp' with eleven attributes. The attributes are shown as follows in ArcGIS:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/189537/image.jpeg)
Then, I used the following expression to read it:
Tree = shaperead('ULS170527All.shp');
The following image shows the field names and data of the 'Tree' variable:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/189538/image.jpeg)
Is this a bug of MATLAB?
Did anyone have the similar problem?
6 Kommentare
Akzeptierte Antwort
Walter Roberson
am 18 Apr. 2018
The code for shaperead contains,
reservedNames = {'Geometry', 'X', 'Y', 'Lat', 'Lon', ... 'BoundingBox', 'Height', 'INDEX'};
I have not yet been able to figure out why Height and INDEX are reserved, but we can see from the code that it is deliberate.
1 Kommentar
Weitere Antworten (0)
Siehe auch
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!