On this page we provide
This version has a lot more functionality than earlier versions: in particular, it allows emulation of the delay in generation of spikes over the neuron's spiking surface, so that the spike shape received can depend on the relative location of the electrode and the neuron's spiking surface. It also runs a lot faster (and has fewer (or possibly only different) bugs). We would appreciate any comments and reports of bugs in this software. There's also some .m files for use in assessing different spike sorting techniques.
We believe it to work.
We are always interested in feedback on these routines. Email lss Note 1: The use of the communications toolbox is restricted to the use of the awgn function, which I use to add some white noise at the end of the data generation. If you can do without that function, simply comment out the line that uses it (line 539 of generatenoisysamples.m), and the software will, I believe, work without the communications tollbox.
Note 2 (added 25 March 2009): The generator generates a waveform made up from spikes, some of which are the target spikes, some noisy spikes whose times are correlated with the target spikes, and some other noisy spikes whose times are not correlated with the target spikes. In the code as made available here, the noisy correlated spikes have their waveform slghtly smoothed relative to that of the target spikes, and the uncorrelated noisy spikes have their waveform further smoothed. We did this because we believed that the signals wouls be somwhat smoothed on their way from neuron to electrode. We now realise that this can give certain types of spike detection algorithms a particular advantage. We intend to introduce a new release in which the degree of this type of smoothing can be adjusted by the user. The relevant code lies between lines 140 and 160 of generatenoisyspikes.m. If you need assistance with this, please contact me.
Note 3 (29 Feb 2012): There's a minor change about lines 77-82, so that the program now expects the directory example6 to be in a subdirectory of where the rest of the software is. In addition, the noise level for the white noise added at the end is now in the varargin setup: so adding
Note 3 (7 July 2017): Some questions and answers.
'NoiseSNR', 10
to the command will alter the white noise level to -10dB, for example. Default remains -100dB. As an aside, this means that the command line
[signals1 target1 r1]= generatenoisysamples('Duration',2,'SampleRate',10000, 'N_Jitter', 0,
'N_Uncorr', 0, 'NoiseSNR', 10) ;
will generate a two second long signal, with two targets (default), no jittered or uncorrelated noise and -10dB white noise added.
A:
This depends on the parameters used in the calls to the two spike generation functions, genspikespoisson and genspikesgaussian.
Each spike train has either a Gaussian or a Poisson distribution, and which is determined by the number of the spike train (starting, because it's Matlab and not C at 1), using the value spikedist(spike train number). This is either a "G"(Gaussian) or a "P" (Poisson).
The actual values used for the Poisson distribution are set in the code, in the variables poissonnumber, and poissonmeanISI. These are used in the call to genspikespoisson as lambda and mean inter-spike interval.
The actual values for Gaussian distributed spike train are set in the variables gaussmeanITD (I should have called this gaussmeanISI, but I didn't) and gaussstdev. These set the mean inter-spike interval and the standard deviation of this inter-spike interval.
This isn't exactly what's done - we also set the minimum inter-spike interval to default at 1 millisecond (value for refractoryperiod), unless reset in the call by setting "RefractoryPeriod" as a varargin.
Note that genspikespoisson and genspikesgaussian are also used (in a similar manner) in the generation of uncorrelated spike trains. In that code, u_poissionnumber(nu), and u_poissmeanISI(nu) are used in the poisson spike trains, and u_gaussmeanITD(nu), u_gaussstdev(nu) are used in the Gaussian spike trains.
A: There's randomisation (call to poissrnd in genspikesgaussian, and call to randn in genspikesgaussian) so that what's generated will be different each time.
[samples target r1]=generatenoisysamples;
Undefined function or variable "targets".
Error in generatenoisysamples (line 365)
if (length(targets) ~= n_targets)
A: I had used calls to exist() with only 1 paramater. This was not a good idea. Fixed in release 1.2. I'm hoping I haven't introduced any new bugs!
What we'd like to do with this software (updated July 2010)
After using this software a little, and talking to others using this software, there are number of upgrades that I'd really like to do.
Back to Professor Smith's home page.
Last updated: Monday, 24-Jul-2017 10:08:15 BST
Prof Leslie S Smith (lss(nospam_please)@cs.stir.ac.uk)