Setting up Paths (unix,osx)


As of April 2013, this version of the documentation is no longer maintained; however, it is consistent with the last (now retired) version of CODAS processing that used Matlab. We no longer update or fix the Matlab processing code, but we will maintain the Matlab code that reads CODAS Matlab output. Although the notes refer to both Python and Matlab processing, none of the code here will be maintained. This (now retired) documentation and code will remain available for awhile longer.

Python processing code is actively maintained and developed, and CODAS Python processing is documented here.

In your .cshrc (or .bashrc, or wherever you keep your shell setup instructions) add to your path the location of the executables for your machine: this includes the binary executables, and the locations of executable and python scripts. If you were to install everything under /home/adcp_programs, you would add the following to your path (path to binaries first, then add path to python code):


  1. python programs:

    • /home/adcp_programs/pycurrents/adcp (for
    • /home/adcp_programs/pycurrents/data/nmea (for parsing NMEA data)
    • /home/adcp_programs/pycurrents/plot (navigation plots)
    • /home/adcp_programs/pycurrents/adcpgui (python gui editor)

    To use, you will need to add this and only this location to your PYTHONPATH environment variable:

    • /home/adcp_programs
  3. To run a Python script, type :




    You should also add the location of the matlab directory which was extracted from to your MATLABPATH. Specifically, add the following to the MATLABPATH environment variable:

    • /home/adcp_programs/matlab
  2. Running programs

    Any time you run matlab programs you should type the following to add the appropriate programs to your path. Alternatively, you can put these commands in your ~/matlab/startup.m file:

  • adcppath; radcppath; mexpath

DO NOT add any subdirectories of /home/adcp_programs/matlab (if using the path tool in matlab, do not add the /home/adcp_programs/matlab directory recursively); only add the directory itself.

IMPORTANT: Add a link from /usr/local/bin/matlab to your matlab executable or will not be able to start matlab.

IMPORTANT: See the section about mex files for more information about the “table1” we use for linear interpolation. This is important to get right and becomes more difficult with each new matlab release.