- 积分
- 485
- 贡献
-
- 精华
- 在线时间
- 小时
- 注册时间
- 2023-3-8
- 最后登录
- 1970-1-1
|
登录后查看更多精彩内容~
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
本帖最后由 yhuan 于 2023-7-16 20:56 编辑
运行报错为:fatal:gc_inout: the rightmost dimension of lat/lon must be at least three.fatal:["Execute.c":8578]:Execute: Error occurred at or near line 357 in file ./shapefile_utils.ncl
fatal:["Execute.c":8578]:Execute: Error occurred at or near line 56 in file data_nec_1.0.ncl
代码为图1
后经排查,应是shp文件引起错误,由于shp文件是从他人电脑拷贝而来,试过plot_shapefile也没啥问题,一直以为没有问题,后来在论坛看见有人遇到类似问题是由shp造成,于是抱着试一试的想法重新制作shp文件,结果代码成功运行。全程无需下载其他软件。
以下附上方法,参考了链接的办法。
1.选择想要的地图 http://datav.aliyun.com/portal/school/atlas/area_selector
2.将代码保存为json形式
3.将json转换为shp文件转shp,大功告成!!!! https://mapshaper.org/
本以为会很麻烦,结果其实很简单。附上中国地区shp
|
-
第3步
-
-
-
cn.zip
256.94 KB, 下载次数: 38, 下载积分: 金钱 -5
|