爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
查看: 222|回复: 3

grads绘图出现问题了

[复制链接]
发表于 4 天前 | 显示全部楼层 |阅读模式
GrADS
系统平台: 在win10系统下用grads2.2.1绘图出现了问题
问题截图: -
问题概况: welcome to http://bbs.06climate.com
Data Request Error: File number out of range
Variable = uwnd.3
Error ocurred at column 1
DISPLAY error: Invalid expression
Expression = uwnd.3*2.5
Data Request Error: Invalid variable name
Variable 'air.2' not found in file 2
Operation Error: Error from smth9 function
Error ocurred at column 1
DISPLAY error: Invalid expression
Expression = smth9(air.2-273.15)
Data Request Warning: Request is completely outside file limits
Cannot contour grid - all undefined values
Data Request Warning: Request is completely outside file limits
Cannot contour grid - all undefined values
我看过提问的智慧: 看过
自己思考时长(天): 2

登录后查看更多精彩内容~

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
我的gs文件:
'reinit'
'set display color white'
'c'

'set grads off'
'set grid off'


'sdfopen D:\necp\hgt.mon.mean.nc'
'sdfopen D:\necp\hgt.mon.ltm.1991-2020.nc'

'set rgb 34  78  84  81'
'set rbcols 34'

**********画地图 设置地图颜色、线型、粗细**********
'set parea 0.30 11.0 0.7 7.8'

'set csmooth on'
'set lat 10 70'
'set lon 70 160'
'set xlpos -20'
'set ylpos -20'

'set clopts -1 -1 0.12'
'set xlopts 1 4 0.18'
'set ylopts 1 4 0.16'
'set strsiz 0.2 0.22'
'set grads off'
'set xlpos -10'
'set ylpos -10'

'set cmin 1000000000000000000'
'd hgt.1'


'set dfile 1'
*lev 高度
'set lev 500'
*t时间
'set t 932'
'set font 0'


**********画气压等值线 设置等值线颜色、间隔、线宽**********
'set gxout contour'
'set ccolor 34'
'set cint 4'
'set cmin 500'
'set cmax 604'
'set cthick 5'
'set clskip 2'
'set cstyle 1'
'set clopts  34 2 0.12'
'set label off'

#'define v1 = hgt.1/10'

'd smth9(hgt.1/10)'


'set clevs 588'
'set ccols 34'
'set cthick 5'
'set clskip 2'
'set clopts  34 1 0.12'
'set label off'
'd smth9(hgt.1/10)'


'set dfile 2'
**lev 高度
'set lev 500'
**t时间
'set t 8'
'set font 0'


'set clevs 588'
'set ccols 15'
'set cthick 5'
'set clskip 2'
'set cstyle 3'
'set clopts  0 3 0.12'
'set label off'
'd smth9(hgt.2/10)'



**********保存图片**********
'gxprint d:\h5002025081.eps white'
'printim d:\h5002025081.pdf white'
'gxprint d:\h5002025081.png white'
'reinit'

密码修改失败请联系微信:mofangbao
发表于 3 天前 | 显示全部楼层
前两年画grads多一点,看到楼主用grads感觉好亲切呀。你的问题我以前也遇到过,是不是经纬度范围超了啊?nc文件经纬度范围和画图设置范围一致吗?
密码修改失败请联系微信:mofangbao
回复 支持 反对

使用道具 举报

 楼主| 发表于 3 天前 | 显示全部楼层
祁萍 发表于 2025-11-12 08:47
前两年画grads多一点,看到楼主用grads感觉好亲切呀。你的问题我以前也遇到过,是不是经纬度范围超了啊?nc ...

nc文件的经纬度在0-90,70-180,绘图的经纬度在0-70  70 -160,能出图
密码修改失败请联系微信:mofangbao
回复 支持 反对

使用道具 举报

发表于 3 天前 | 显示全部楼层
本帖最后由 苏拉苏拉 于 2025-11-12 20:45 编辑

Variable 'air.2' not found in file 2。这个变量在文件2里没有。Data Request Error: File number out of range
Variable = uwnd.3
没有文件3

密码修改失败请联系微信:mofangbao
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Copyright ©2011-2014 bbs.06climate.com All Rights Reserved.  Powered by Discuz! (京ICP-10201084)

本站信息均由会员发表,不代表气象家园立场,禁止在本站发表与国家法律相抵触言论

快速回复 返回顶部 返回列表