爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博登陆

只需一步, 快速开始

搜索
查看: 5148|回复: 0

NCL

[复制链接]

新浪微博达人勋

发表于 2016-7-2 12:53:28 | 显示全部楼层 |阅读模式
GrADS
系统平台:
问题截图: -
问题概况: 用NCL做掩膜处理,即将有效值范围外的值设置为0,报错
我看过提问的智慧: 看过
自己思考时长(天): 1

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

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

x
用NCL做掩膜处理,程序如下:
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/shea_util.ncl"
begin
a = addfile("MOD15A2.A2008057.h25v03.005.2008068113323.hdf","r")
lai1 = a->Lai_1km
if (lai1 .le.    80) then
  lai = lai1
    else
  lai  = lai1*0
end if
b = addfile("new.hdf","c")
b->LAI = lai
end
报错信息如下:
Copyright (C) 1995-2013 - All Rights Reserved
University Corporation for Atmospheric Research
NCAR Command Language Version 6.1.2
The use of this software is governed by a License Agreement.
See http://www.ncl.ucar.edu/ for more details.
fatal:Conditional statements (if and do while) require SCALAR logical values, see all and any functions
fatal:["Execute.c":8128]:Execute: Error occurred at or near line 13 in file ym.ncl


不懂是为什么,看了好多别人的程序都是这样写的啊?求指点
密码修改失败请联系微信:mofangbao
您需要登录后才可以回帖 登录 | 立即注册 新浪微博登陆

本版积分规则

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

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

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