Procedures for displaying acoustics data using MATLAB®

The acoustics backscattering data on CD#2 and CD#3 may be displayed using Matlab® routines. Matlab® is a product of The MathWorks, Inc. and may be purchased on-line from mathworks.com.

Here is a brief description of the procedures and mfiles used to make 3D "curtain" plots and 2D "data as a function of time or distance" plots of the acoustic backscattering data collected during the Workshop-at-Sea.

Included on this CD are a series of nested mfiles with the following hierarchy.
You may download these files or use them directly from the CD:

curtain.m
setupplt.m
doplot.m
clegend5.m
cmap.m

tdist.m
spdfil.m
gpsfix.m
(The code for this file is also inside doplot.m)
(Note: the above three files are not currently used by doplot.m)

quitplot.m

Begin by unzipping the ascii data files (e.g. f017986/d930612/t202037d.gz).

Then load the data into the MATLAB® workspace.

Running curtain.m on the MATLAB® command line calls the other mfiles.

The setupplt.m mfile puts up a window that lets you change the file name and some other properties of the plot. You must put the filename in the place which asks for it. Loading the file alone will not tell the program which file to plot.

doplot.m does the work of plotting the data and it calls a couple of other files to assist with the color mapping. Doplot also turns on rotate3d, so that you can use your cursor to rotate the 3-D plot image.

The mfiles to fix the position data are no longer used by Doplot. Normally the position data are fixed before running curtain.m.
The code for gpsfix.m is actually in doplot.m, but only as commented text now.

quitplot.m closes the menu window and clears the workspace of working matricies, but it does not clear the 3D figure.

The data format:

Curtain assumes the data to be plotted are in a format that consists of a series of rows each with:
yearday_time, lat, lon, tran, mindepth, maxdepth, depthint,sv1,sv2,sv3....svn

In other words, each row has the data from one integration time interval with the first seven columns describing the data and columns eight to n with the sv data from each depth strata.

The column designated "tran" simply has the transducer frequency in it i.e. 120 for 120 kHz.

Another set of mfiles is present which enables the 2D plotting of the acoustics data as a function of time or distance.

The two files:

callplot.m
plotgb.m
also use other mfiles listed above, including gpsfix.

When run on the MATLAB® command line, callplot.m puts up a figure window and then presents input lines to specify needed inputs to make the plot, i.e.

input number of plots on figure (Number of plots can range from 1 to 4)
input name of matrix to plot (Specify the name of the file with data format as specified)
input 1 if distance, 2 if time plot
input 1 if moc overplot, 0 if no overplot (it is possible to overlay other data over the echogram)
input label for figure (After typing a text label, use the cursor to place it on the highlighted feature on the plot)
input figure title (Type a figure label and hit return)

Following the automatic placement of the figure legend, use the cursor to first place the y-axis label [Depth (meters)] and then the x-axis label [Time (Yearday) or Distance (meters)].