One can imagine several ways that a neuron might respond to a sinusoidal input, which is our normal visual input. First, let's express the sinusoidal input signal S as a function of time. We will write out 20 seconds of time in 1ms steps. Before time 0, the signal will be 0, and it will start being sinusoidal at time 0.
There are many ways that our neuron could respond to this signal. Let's first think about its voltage response. The voltage could simply fluctuate sinusoidally as a function of time.
![png](output_3_0.png) If we had the output signal Y_1, how can we measure the magnitude of the response? We'd ideally like to measure the amplitude of the sinusoidal response. The technique for doing this is called Fourier analysis (Lab 3.2). We have a Matlab function that performs Fourier analysis: **
A =
-0.2732 + 0.4187i
The fourier coefficient at 4 Hz is a complex number that has a magnitude and phase. Let's check out the magnitude by using the **
ans =
0.5000
We got a value of 0.4940, which is very close to the magnitude of the acutal response (0.5). If there were no delay, then this would be exactly right. Another cell might give a response that looks like this:
Here, the voltage response to the input with a fixed step. Taking the mean of the response does a good job of capturing the response.
B =
0.5000
So, here again we have a value very close to the true function that was used to generate, with the only small difference arising from the delay in the response. We can also imagine a mixed response, like the following:
We can calculate the mean of this response, and the F1 response (the amplitude of the response at the fundamental stimulus):
B_ =
0.5000
Even though this captures the mean response very well, it does not describe the full response. It does not describe the sinusoidal modulation of the response. To capture this, we must also examine the F1 of the response:
A_ =
-0.2732 + 0.4187i
ans =
0.5000
Now, together, these two numbers (the mean, also called F0, and F1, the amplitude of the signal at the stimulus frequency) capture the response of the cell pretty well. We could also imagine that we do not have a voltage response, but, instead, we have a firing rate that is based on this voltage response. For the moment, we will let the **
We can calculate the probability that the cell fires in any given millisecond by calculating:
Now we can generate some spikes by drawing random numbers:
We can calculate the mean response:
F_mean =
5.1500
The mean response has units of spikes/sec. But knowing the mean response doesn't fully describe the whole response. We need to consider the rhythmicity of the signal as well by calculating the F1. For calculating this for spikes, we will find the spike times and compute the fourier transform:
F1_resp_manual =
-3.2691 + 3.7591i
ans =
4.9817
F1_resp =
-3.2691 + 3.7591i
ans =
4.9817
This indicates that the response has a high degree of rhythmicity; the magnitude is the same size as the mean response. It has the units of spikes/sec. |

-Techniques and tricks > Matlab >