Problem with freqstatistics

Jean-Michel Badier jean-michel.badier at UNIVMED.FR
Wed May 27 21:16:12 CEST 2009

Dear Fieldtrip mailing list members,

I am a quite new user of fieldtrip (version 10090331).
I have been trying to use it for analyzing distribution of frequencies
on MEG signal between two events of a task.
The last command using freqstatistics result of an error message.
I decided to run the tutorial "Cluster-based permutation tests on
time-frequency data" in order to compare the organization my data set
compared with the one in the data set. In fact I got the same bug with
the tutorial data set that is for the tutorial data set:

selected 149 channels
selected 61 time bins
selected 1 frequency bins
Warning: PACK can only be used from the MATLAB command line.
 > In fieldtrip-20090331/private/prepare_timefreq_data at 314
  In fieldtrip-20090331/private/statistics_wrapper at 315
  In freqstatistics at 137
Using the gradiometer configuration from the dataset.
there are on average 4.7 neighbours per channel
using "statistics_montecarlo" for the statistical testing
using "statfun_indepsamplesT" for the single-sample statistics
constructing randomized design
total number of measurements     = 149
total number of variables        = 1
number of independent variables  = 1
number of unit variables         = 0
number of within-cell variables = 0
number of control variables      = 0
using a permutation resampling approach
computing a parmetric threshold for clustering
Warning: Not all replications are used for the computation of the
 > In statfun_indepsamplesT at 90
  In statistics_montecarlo at 275
  In fieldtrip-20090331/private/statistics_wrapper at 381
  In freqstatistics at 137
Undefined function or method 'tinv' for input arguments of type 'double'.
??? Error using ==> statistics_montecarlo at 278
could not determine the parametric critical value for clustering

Error in ==> statistics_wrapper at 381
  [stat, cfg] = statmethod(cfg, dat,;

Error in ==> freqstatistics at 137
[stat] = statistics_wrapper(cfg, varargin{:});


Any idea or suggestion about that problem?



Jean-Michel Badier

Laboratoire de MagnétoEncéphaloGraphie

INSERM U751. Aix Marseille Université

33 (0)4 91 38 55 62

_jean-michel.badier at univmed.fr_ <mailto:jean-michel.badier at>

Service de Neurophysiologie Clinique. CHU Timone

264 Rue Saint-Pierre, 13005 Marseille-France

The aim of this list is to facilitate the discussion between users of the FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also and
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the fieldtrip mailing list