<div dir="ltr">Hello,<br><div><br></div><div>    I am trying to write out one variable in HDF5 format in an NCL script following the commands on the web page <a href="https://www.ncl.ucar.edu/Applications/hdf5.shtml">https://www.ncl.ucar.edu/Applications/hdf5.shtml</a>.  Because the output data are calculated in the NCL script, I commented the three lines below.  However, I got the error message &quot;NclFileAddGrp: Old File Structure DO NOT Support Group.&quot; as follows.  Could anyone indicate how to fix this error?</div><div><br></div><div>    Thanks much,</div><div><br></div><div>                   Yi-Chih</div><div><br></div><div><br></div><div><div>fatal:[&quot;FileSupport.c&quot;:1638]:_NclFileAddGrp: Old File Structure DO NOT Support Group.</div><div>^Mfatal:[&quot;FileSupport.c&quot;:1638]:_NclFileAddGrp: Old File Structure DO NOT Support Group.<br></div><div>^Mfatal:[&quot;FileSupport.c&quot;:1638]:_NclFileAddGrp: Old File Structure DO NOT Support Group.<br></div><div>^Mfatal:[&quot;Execute.c&quot;:8128]:Execute: Error occurred at or near line 340 in file q_ln-ln_pre_q01.ncl<br></div></div><div><br></div><div>##########################################</div><div><div>;<span style="color:rgb(0,0,0);font-family:courier;font-size:13.3333px"> fn = &quot;/Users/huangwei/myncl/nc4_work/wrtgroup/<a href="http://nc4uvt.nc">nc4uvt.nc</a>&quot;</span></div><pre style="margin-top:0px;margin-bottom:0px;padding:0px;font-size:13.3333px;line-height:12pt;font-family:courier;border-style:solid;border-width:0px 0px 15px;border-color:transparent;color:rgb(0,0,0)">; fi = addfile(fn, &quot;r&quot;)</pre></div><div>;  fAtt@source_file   = fn<br></div><div><br></div><div>##########################################     as on the web page <a href="https://www.ncl.ucar.edu/Applications/hdf5.shtml">https://www.ncl.ucar.edu/Applications/hdf5.shtml</a></div><div><pre style="margin-top:0px;margin-bottom:0px;padding:0px;font-size:13.3333px;line-height:12pt;font-family:courier;border-style:solid;border-width:0px 0px 15px;border-color:transparent;color:rgb(0,0,0)"><p style="margin:10px 0px 20px;padding:0px;color:rgb(51,51,51);font-family:verdana,sans-serif;font-size:10pt;line-height:12pt">        Write HDF5 file with group:
</p><pre style="margin-top:0px;margin-bottom:0px;padding:0px;font-size:10pt;line-height:12pt;font-family:courier;border-style:solid;border-width:0px 0px 15px;border-color:transparent;text-indent:0em"> setfileoption(&quot;nc&quot;, &quot;FileStructure&quot;, &quot;Advanced&quot;)

 fn = &quot;/Users/huangwei/myncl/nc4_work/wrtgroup/<a href="http://nc4uvt.nc">nc4uvt.nc</a>&quot;

 fi = addfile(fn, &quot;r&quot;)

;printVarSummary(fi)
;print(fi)

 time = fi-&gt;time
 lev = fi-&gt;lev
 lat = fi-&gt;lat
 lon = fi-&gt;lon

 t = fi-&gt;T
 u = fi-&gt;U
 v = fi-&gt;V

;printVarSummary(t)
;printVarSummary(u)
;printVarSummary(v)

;print(&quot;t(0,0,0,0) = &quot; + t(0,0,0,0))
;print(&quot;u(0,1,1,1) = &quot; + u(0,1,1,1))
;print(&quot;v(0,2,2,2) = &quot; + v(0,2,2,2))

;print(&quot;t&amp;lat(0) = &quot; + t&amp;lat(0))
;print(&quot;t@units = &quot; + t@units)
;print(&quot;u@units = &quot; + u@units)
;print(&quot;v@units = &quot; + v@units)

;u1 = fi-&gt;U(::2)
;v1 = fi-&gt;V(3:121:3)

 ntim  = dimsizes(time)         get dimension sizes
 nlev  = dimsizes(lev)
 nlat  = dimsizes(lat)
 nlon  = dimsizes(lon)

;------------------------------------------------------------
 setfileoption(&quot;h5&quot;, &quot;FileStructure&quot;, &quot;Advanced&quot;)

 fon = &quot;ncl_wrt_uvt.h5&quot;
 system(&quot;/bin/rm -f &quot; + fon) ; remove if exists
 fo = addfile(fon, &quot;c&quot;)

;===================================================================
; explicitly declare file definition mode. Improve efficiency.
;===================================================================
;setfileoption(fo,&quot;CompressionLevel&quot;, 6)
;setfileoption(fo,&quot;CacheSize&quot;, 3200000)
;setfileoption(fo,&quot;CacheNelems&quot;, 1027)
;setfileoption(fo,&quot;CachePreemption&quot;, 0.25)
</pre><div>..............</div></pre></div></div>