HELP WITH BASIC UNIX COMMANDS

Learning Unix

is not always easy for those of us who have grown up with Windows and the Macintosh. It's worth saying that once you are used to it, it is extremely powerful, and the other platforms can feel cumbersome by comparison. Anyway, enough propaganda.

There are a lot of guides to learning Unix on the web. Below are some links to a few of them. However, there is so much to Unix, that I have also made a list of Unix things we imagers often use. I suggest that you have a quick look at the list, and then try one of the tutorials. The list may be useful later on, for tips on things you might not have considered (such as archiving, killing dead processes etc).

Tip: If you have a problem, just try typing it (or the error message, if there is one) into Google, and there is a good chance you may find the answer. Clearly, the more specific you can make the words you use, the better Google will be able to find the answer. This advice applies to learning Linux, finding the nearest florist, a lack of libido, or all manner of other situations. Google is your friend.

Unix tutorials

So, maybe you would like to try one of the many good unix tutorials on the web. Here are a couple of links to start: * The CBU has some excellent commercial guides to Unix and its various utilities. CBU users should start at the CBU Unix support page (sorry, this page is not available outside the Unit).

Things we think you might want to know about Unix

Here is a list of the commands and concepts that we have found useful in learning Unix. We suggest these so that you will have some idea what to concentrate on if you go ahead and look at the unix tutorials. * It is essential to understand unix directory structure, and how paths work. Things you will come across are:

Some first tips

In general: don't forget to be careful of case and of spaces in typing commands and file names. Remember that unix, unlike MSDOS and Windows, cares about UPPER and lower case.Consider using emacs as your text editor. It has a load of useful features, will show you directory listings in a useful format, has special features for editing matlab and c programs, and is an excellent way to get to the unix "man" help pages.

Unix and SPM

There is little that you need to know about unix that is specific to SPM. The one key thing is the way that SPM stores its analyses. SPM stores all its analysis files in the current directory. This is, by default, the directory from which you start matlab, or, at the CBU, the directory from which you start SPM (at the CBU we have an automatic SPM and then matlab startup script - see the SPM versions page ). This directory will contain the postscript file containing the results printouts, and the analysis files, from the statistics. If you start SPM in a directory which has analysis files in it, the analysis files may be overwritten. So, to save a new analysis without losing the old analysis, make a new directory, or change to a directory where you want the results files, and start SPM from there. Alternatively, you can use the SPM "Utils" button, and the "CD" option there, to change directory after you have started SPM. Warning: don't change directory within matlab/SPM, using the "cd" command in the matlab window; it may not work as expected.

MatthewBrett 11/10/99