From vschmidt at ccom.unh.edu  Wed Feb 21 15:51:09 2007
From: vschmidt at ccom.unh.edu (Val Schmidt)
Date: Wed Feb 21 15:55:00 2007
Subject: [Sea-mat] Possible bug in carter.m
Message-ID: <0F50AEBB-F4B1-4CAD-A162-18EFC1BF29BB@ccom.unh.edu>

Mike,

First, thanks so much for your carter.m matlab routine for accessing  
Carter's tables. It has been tremendously helpful.

In the course of my work, I think I found a small bug in the code. In  
these lines:

-------snip---------
% now scan through longitudes to find correction area

for i = 1:length(lon_file)-1;
     if lon_use >= lon_file(i) & lon_use < lon_file(i+1);
         correction_area(ii) = area(i);
     elseif lon_use > lon_file(end);
         correction_area(ii) = area(end); % if is on last record in  
group
     end;
end;
----------snip---------

...it turns out that if "lon_use", (the longitude for which one would  
like a correction) happens to be equal to the "lon_file(end)", (the  
last value in the list of area longitude boundaries), then no area is  
selected (i.e. area_correction is not set) and subsequent lines of  
code fail.

A simple (and I *think* proper) fix is to modify the second elseif  
statement to the following:

      elseif lon_use >= lon_file(end);

[Note the added "=".]

I am not entirely sure this is correct and I defer to your judgement.

The copy of carter.m I have was borrowed from the USGS - SEA-MAT site:
http://woodshole.er.usgs.gov/operations/sea-mat/.

I have cc'd their mailing list.

Cheers,

-Val

------------------------------------------------------
Val Schmidt
CCOM/JHC
University of New Hampshire
Chase Ocean Engineering Lab
24 Colovos Road
Durham, NH 03824
e: vschmidt [AT] ccom.unh.edu
m: 614.286.3726


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.whoi.edu/pipermail/sea-mat/attachments/20070221/19583720/attachment.htm
From mmm at bas.ac.uk  Thu Feb 22 00:57:21 2007
From: mmm at bas.ac.uk (Michael Meredith)
Date: Thu Feb 22 12:03:33 2007
Subject: [Sea-mat] Re: Possible bug in carter.m
Message-ID: <s5dd30da.004@bsnw.nerc-bas.ac.uk>

Hi Val

Glad you found the Carter code useful; thanks for getting in touch about
this.

Im actually on my travels at the moment, so can't shake down the code
very easily right now - but from a quick scan it does look like the
extra equals sign might help in the specific circumstance you mention.
I'll let you know more once Ive looked in detail.

Good spot; if you find any more bug fixes, do please flag them up, they
are much appreciated.

Best wishes
Mike


***********************************************
Dr. Mike Meredith
Head of Atmosphere and Ocean Group
British Antarctic Survey
High Cross
Madingley Road
Cambridge CB3 0ET
United Kingdom

http://www.antarctica.ac.uk/staff-profiles/template.php?user=mmm

>>> Val Schmidt <vschmidt@ccom.unh.edu> 02/21/07 8:51 PM >>>
Mike,

First, thanks so much for your carter.m matlab routine for accessing  
Carter's tables. It has been tremendously helpful.

In the course of my work, I think I found a small bug in the code. In  
these lines:

-------snip---------
% now scan through longitudes to find correction area

for i = 1:length(lon_file)-1;
     if lon_use >= lon_file(i) & lon_use < lon_file(i+1);
         correction_area(ii) = area(i);
     elseif lon_use > lon_file(end);
         correction_area(ii) = area(end); % if is on last record in  
group
     end;
end;
----------snip---------

...it turns out that if "lon_use", (the longitude for which one would  
like a correction) happens to be equal to the "lon_file(end)", (the  
last value in the list of area longitude boundaries), then no area is  
selected (i.e. area_correction is not set) and subsequent lines of  
code fail.

A simple (and I *think* proper) fix is to modify the second elseif  
statement to the following:

      elseif lon_use >= lon_file(end);

[Note the added "=".]

I am not entirely sure this is correct and I defer to your judgement.

The copy of carter.m I have was borrowed from the USGS - SEA-MAT site:
http://woodshole.er.usgs.gov/operations/sea-mat/.

I have cc'd their mailing list.

Cheers,

-Val

------------------------------------------------------
Val Schmidt
CCOM/JHC
University of New Hampshire
Chase Ocean Engineering Lab
24 Colovos Road
Durham, NH 03824
e: vschmidt [AT] ccom.unh.edu
m: 614.286.3726




--  
This message (and any attachments) is for the recipient only.  NERC is subject
to the Freedom of Information Act 2000 and the contents of this email and any
reply you make may be disclosed by NERC unless it is exempt from release under
the Act.  Any material supplied to NERC may be stored in an electronic
records management system.

From yarmey at coast.ucsd.edu  Wed Mar 28 01:15:58 2007
From: yarmey at coast.ucsd.edu (Lynn Yarmey)
Date: Wed Mar 28 07:04:05 2007
Subject: [Sea-mat] GUI multi-axes plotting question
Message-ID: <532ADF71-B5CF-4A33-A863-5D6B9BCB8787@coast.ucsd.edu>


Hello all!

I am very sorry to bulk up your inboxes, but I am hoping someone can  
help me with a (hopefully) quick question!     I am creating a GUI  
for at-sea CTD visualizations, so there are 4 axes with drop downs to  
switch variables,  depth range limit boxes, etc.   I am using GUIDE.

My problem:   I would like to have a default set of figures come up  
when the GUI is started rather than force the user to use the drop- 
downs to see figures.   When I try to enter any plotting lines in the  
'OpeningFcn' my drop-down boxes no longer appear.   When I step  
through the script in the debugger, the menus appear as normal.    If  
I keep all plotting code after the popup Callbacks (ie. so axes are  
blank on startup) and only have data loading and handle assignments  
in the OpeningFcn, everything works nicely.

I thought I might have been altering necessary handles or the initial  
definition of hObject but I can't see where this is happening!?

Any thoughts?  Sloppy writing?  Fundamental misunderstandings?    
Places where I can find better GUI help (the demos are great, but I  
can't find anything in the matlab support pages)?

I am attaching a word document with before and after screen shots  
(please disregard the lack of colorbars in the latter) and what I  
believe are the problematic lines.

I am running R14 on a Windows machine.   (The problem does not occur  
when I am on my mac running R2006a)

Many thanks!
Lynn Yarmey
SIO

-------------- next part --------------
A non-text attachment was scrubbed...
Name: disappearingDropDowns.doc
Type: application/octet-stream
Size: 167936 bytes
Desc: not available
Url : http://mailman.whoi.edu/pipermail/sea-mat/attachments/20070327/9085c8dd/disappearingDropDowns-0001.obj
From julioccb at gmail.com  Wed May 30 13:19:31 2007
From: julioccb at gmail.com (Julio Castro)
Date: Wed, 30 May 2007 13:19:31 -0400
Subject: [Sea-mat] adjunto toolbox
Message-ID: <24de456c0705301019x1e43c9e6n5471811f8eb09272@mail.gmail.com>

Adjunto toolbox, el cual apoya los trabajos de analisis de series de viento
atmosferico y corrientes oceanicas.
Este contiene un demo basado en mediciones de 2 meses de viento en Cochrane
- XI region. CHILE.

Julio Castro.
Oceanografo.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.whoi.edu/pipermail/sea-mat/attachments/20070530/14e1e037/attachment-0001.htm 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: wind.rar
Type: application/octet-stream
Size: 47406 bytes
Desc: not available
Url : http://mailman.whoi.edu/pipermail/sea-mat/attachments/20070530/14e1e037/attachment-0001.obj 

