<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
</head>
<body text="#000000" bgcolor="#FFFFFF">
Thanks, Dave and Dennis. <br>
<br>
It's all fixed now. The simple application of strategically placed
print, printVarSummary and printMinMax statements for key variables
was a great help in solving my problem. I also really appreciated
the pointer to the use of the where() and ind() functions.<br>
<br>
The revised data, code and final figure produced are here: <a
class="m_2090230600965030089gmail-m_-2611889024136365999gmail-m_8218959853096267226moz-txt-link-rfc2396E"
href="https://my.pcloud.com/publink/show?code=kZsanC7ZlKPCnfV5wnLFWm4C2yCww4mtUIYV"
target="_blank"><https://my.pcloud.com/publink/show?code=kZsanC7ZlKPCnfV5wnLFWm4C2yCww4mtUIYV></a>.<br>
<br>
Best fishes<br>
Sam<br>
<br>
<div class="moz-cite-prefix">On 13/01/19 2:29 PM, Dave Allured -
NOAA Affiliate wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CALqwTFMA7SoTMyjH2=U+AeZn=Ge44RgRViuas1X-Y=wi1eX4=w@mail.gmail.com">
<meta http-equiv="content-type" content="text/html;
charset=windows-1252">
<div dir="ltr">
<div dir="ltr">Frequently the most relevant error message is the
first one printed. That is true in this case: "<span
style="color:rgb(0,0,0);font-family:arial,sans-serif">NetCDF:
One or more variable sizes violate format constraints".</span>
The message about define mode is not relevant. However, the
later reference to line 89 is important.</div>
<div dir="ltr"><br>
</div>
<div>"Violate format constraints" probably means that the write
statement at line 89 (fishing_hours) is trying to expand your
output file past the 2-Gbyte normal limit for a netcdf-3
file. Use printVarSummary just before that write statement,
to examine the dimensions of the output variable.</div>
<div><br>
</div>
<div>Also try inserting a temporary "exit" statement just before
the write statement, to examine the format and current
dimensions of the output file at an intermediate stage, with
the ncdump -hs shell command. Between the file dump and size
information from printVarSummary above, you may find the cause
of this particular error.</div>
<div><br>
</div>
<div>If you need to write more that 2 Gbytes, then switch to
"netcdf-4 classic" output format. See documentation for
addfile and setfileoption for how to select the output format
when creating a new file.</div>
<div><br>
</div>
<div>I offer these debugging suggestions because I can not
analyze your script for you. I can help interpret diagnostic
messages.</div>
<div><br>
</div>
<div>Also please note that you copied one of my previous
corrections improperly. In all cases the longitude offset
should be +360, never +180.</div>
<div><br>
</div>
<div>Good luck.</div>
<div><br>
</div>
<div>--Dave</div>
<div dir="ltr"><br>
</div>
</div>
</blockquote>
<div class="moz-signature">-- <br>
<meta content="text/html; charset=windows-1252"
http-equiv="content-type">
<title>email signature</title>
Sam McClatchie (fisheries oceanographer)<br>
& Elena Turin (accounting & auditing)<br>
FishOcean Enterprises<br>
38 Upland Rd, Huia, Auckland 0604, New Zealand<br>
cell: 027 752 8495<br>
<span style="text-decoration: underline;"><a
href="http://www.fishocean.info">Internet</a></span><br>
<img style="width: 150px; height: 149px;" alt=""
src="cid:part3.7B70C3A9.03CA09DD@fishocean.info"><br>
<br>
"The time has come", the tui said,<br>
"to talk of many things:<br>
Of songs - and ferns - and flowering flax,<br>
of Pukekos and dreams ..."<br>
<br>
(not Lewis Carroll)
</div>
</body>
</html>