Nishemo
Nishemo is a utility for generating model hemodynamic filters based on the
Gauss, Poisson, gamma or identity functions.
Invocation
java Nishemo
This starts up the java interpreter and runs the Nishemo
application. You need to have
set up your environment for java
in order for this to work.
Nishemo window
General Fields
- Output file
Name of the ascii file that will contain the filter
values.
Filter notes: This program will always produce a zero centered odd length
filter, so that it can be easily used by the nisfilter program, which uses the
Numerical Recipes in C conv() function. The duration that is entered (see below)
is always measured from the starting point t=0. The user does not need to deal
with the filter values for timepoints where t < 0. These are simply automatically
generated so as to make a temporally centered filter. The filter text file has
2 colunms. First column is the timepoint (in seconds) when the sample was taken.
Second column is that value of the filter at that timepoint.
- Filter duration
Temporal duration of the filter that will be constructed, in seconds (not TR units).
Note: the number of elements in the filter for timepoints > 0 will be
(filter duration)/(sampling interval).
- Sampling interval
The temporal duration of each element in the filter. In discrete signal processing terms
the sampling interval is equal to 1/fs, where fs is the sampling frequency.
Typically, one would enter the TR for fMRI time series data in this field.
Hemodynamic Functions
- gauss
Select Gaussian model function.
The equation for the Gaussian model is:
s(t) = [1/(sqrt(2*pi*sigma²))] * exp(- (t-mean)²/sigma²)
Where t is the timepoint, sigma is the width (variance) of the Gaussian
distribution, and mean is the mean (ie center) of the Gaussian distribution.
exp is the exponential function (e^x).
The model parameters to be entered for the Gaussian function in the Filter Parameters section of the GUI are:
- mean: The mean of the Gaussian distribution. This corresponds to the lag
of the hemodynamic filter.
- FWHM: The Full Width Half Max of the Gaussian distribution. This
controls the dispersion of the hemodynamic filter. FWHM is a function of the
sigma variable in the equation:
sigma = fwhm / (2.0 * sqrt(-2.0 * log(0.5))) log is natural log.
- poisson
Select Poisson model function.
The equation for the Poisson model is:
s(t) = lambda^t * [exp(-lambda) / t!]
Where t is the timepoint, exp is the exponential function (e^x), ^ is the
exponentiation operator (x^y means x raised to the y power), and ! is the
factorial function.
The model parameter to be entered for the Poisson function in the Filter Parameters section of the GUI is:
- lambda: lambda is a single parameter controlling both the lag and
dispersion of the Poisson function. Lag is equal to dispersion because in a
Poisson distribution mean is equal to variance. Note that because of the
factorial function, which is only defined for integer values, t must be an
integer value. This means that the Sampling Interval entered in the first
section of the GUI must be an integer if you select the Poisson function. Scans
with a non-integral TR cannot use the Poisson model.
- gamma
Select gamma model function.
The equation for the gamma model is:
s(t) = [ theta2 * [(theta2*t)^(theta1 - 1)] * exp(- theta2*t)] / gamma(theta1)
Where t is the timepoint, ^ is the exponentiation operator, exp is the exponential
function (e^x), and gamma is the mathematical gamma function.
The model parameters to be entered for the gamma function in the Filter Parameters section of the GUI are:
- theta1 and theta2. Theta1 and Theta2 do not uniquely determine
lag and dispersion. ie, there are different combinations of theta1 and theta2
that may yield essentially the same lag and dispersion values. Very roughly,
you can think of theta1 as a shape parameter and theta2 as a scale parameter.
Or, lag is determined by theta1/theta2 and dispersion is determined by
theta1/theta2²
- identity
Select identity model function.
The equation for the identity filter is:
s(t) = 0 when t does not equal shift
s(t) = scale when t=shift
The model parameters to be entered for the identity function in the Filter Parameters section of the GUI are:
- shift: how many units (units are in sampling interval units) to shift the signal
- scale: signal is scaled by this factor.
Notes: The effect of convolving a signal with this filter is to shift and
scale the given signal:
s(t) = s(t-shift)*scale
The identity filter is primarily used for debugging purposes, but, it could
be used to rescale a dataset.
Options
- Use output run window
Check this box if you want the output run window displayed. This will show the command
line call made to the nishemo C program, and any error diagnostics from that program.
- View results
Check this box to have a plot of the selected filter displayed.
Note that for continuous functions (Gauss, gamma) the filter
plot (green color) will be overlaid on a densely sampled version
(red color) of the filter, to make the discrete sampling more clear.
The green dots are your actual filter values. The green lines just
connect the green dots for visual effect.
If you use the spreadsheet button on the graph window, you will get a number of
columns in the spreadsheet, all with filter values. This is because a number
of copies of the filter were overlaid in the graph to get the densely sampled
red background, and, to get the dots on top of the curves. The spreadsheet shows
everything that went into the graph. The last column should always be your actual
filter values.
- Overwrite output file
Check this box if you would like to automatically overwrite the filter output
file with the current model selection. This is useful if you are experimenting
with many model parameters and only want to save your most recent choice.
References
Equations and information about the model functions was obtained from:
Boynton, G.M., Engel, S.A., Glover, G.H., Heeger, D.J., "Linear Systems Analysis
of Functional Magnetic Resonance Imaging in Human V1.", The Journal of Neuroscience,
July 1, 1996, 16(13):4207-4221.
Lange, N., Zeger,S., "Non-linear Fourier Time Series Analysis for Human Brain
Mapping by Functional Magnetic Resonance Imaging.", Journal of the Royal Statistical
Society, Applied Statistics, 1997, 46 No. 1 pp 1-29.
Press, W.,H., et al, Numerical Recipes in C, Cambridge University Press,
1988.
Rajapakse, J.C., Kruggel, F., Maisog, J.M., Cramon, D., "Modeling Hemodynamic
Response for Analysis of Functional MRI Time-Series.", Human Brain Mapping,
6:283-300(1998).
Last updated Wed Apr 05 13:20:01 EDT 2000