Clean up repeated parts of sigma section

This commit is contained in:
Dennis Huben 2024-09-03 12:01:37 +02:00
parent f35fa7cfcb
commit a5a751401e
3 changed files with 125 additions and 48 deletions

BIN
main.pdf

Binary file not shown.

Binary file not shown.

173
main.tex
View File

@ -628,10 +628,24 @@ To confirm that the $\sigma$ parameter estimated from the fit is indeed a good m
We tried several different bin sizes (30 to 300 bins) and spike widths. There was little difference between the different parameters (see appendix).
\section*{Electric fish as a real world model system}
To put the results from our simulations into a real world context, we chose the
weakly electric fish \textit{Apteronotus leptorhynchus} as a model system.
\lepto\ uses an electric organ to produce electric fields which it
uses for orientation, prey detection and communication. Distributed over the skin
of \lepto\ are electroreceptors which produce action potentials
in response to electric signals.
These receptor cells ("p-units") are analogous to the
simulated neurons we used in our simulations because they do not receive any
input other than the signal they are encoding. Individual cells fire independently
of each other and there is no feedback.
\subsection*{Electrophysiology}
We can see from figure \ref{sigmafits_example} that the fits look very close to the data. Due to the gaussian signal distribution there are fewer samples for very weak and very strong inputs. In these regions the firing rates become somewhat noisy. This is especially noticeable for strong inputs, as there are more spikes there, and therefore large fluctuations, while there is very little spiking anyway for weak inputs.
We can see from figure \ref{sigmafits_example} that the fits look very close to the data. Due to the gaussian signal distribution there are fewer samples for very weak and very strong inputs. In these regions the firing rates become somewhat noisy. This is especially noticeable for strong inputs, as there are more spikes there, and therefore large fluctuations. Fluctuations are less visible for weak inputs where there is very little spiking anyway.
\begin{figure}
\includegraphics[width=0.4\linewidth]{img/ordnung/cropped_fitcurve_0_2010-08-31-ad-invivo-1_0.pdf}
@ -660,51 +674,10 @@ Noisier cells have a lower coding fraction for small populations. For increasing
\label{ephys_sigma}
\end{figure}
\subsection*{Determining the strength of noise in a real world example}
While in simulations we can control the noise parameter directly, we cannot do so in electrophysiological experiments.
Therefore, we need a way to quantify the intrinsic noise of the cell from the output of the measured cells. Common measures to quantify noisiness of neuronal spike trains are not directly correlated with intrinsic noise strength (figure \ref{noiseparameters}). An example for such a measure is the coefficient of variation (cv) of the interspike interval (ISI)\citep{white2000channel, goldberg1984relation,nowak1997influence}. The ISI is the time between each consecutive pair of spikes. The coefficient of variation is then defined as the standard deviation of the ISI divided by the mean ISI. Even though it is frequently used, we find that the cv as a function the intrinsic noise in our LIF-simulations is not necessarily monotonously related. In addition, for different membrane constants, which determine how quickly a neuron reacts to inputs, the same intrinsic noise results in widely different cv-values. Refractory periods also have an influence on the cv.
\notedh{their/holt1996 cv2 looks interesting.}
Another measure which has been used before is the standard variation of the peri-stimulus spike histogram
\citep{mainen1995reliability} \notedh{can't find any paper which did something like we did here, even though Schreiber et al. 2003 A new correlation-based measure of spike timing reliability - claim it's frequently done with psth}. This approach also does not work well, as it also depends on the membrane constant and to a lesser extend the refractory period.
The approach used here uses the activation curve of the neuron, fitting a function to it and extracting the parameters from the fitted function. It is assumed that the neurons show Gaussian noise. The mean of the distribution is the activation threshold and the width of the Gaussian is a measure for noise.
The probability of spiking as a function of the input is then the integral over the Gaussian, i.e. an error function.
Stocks (2000) uses one such function to simulate groups of noisy spiking neurons:
\begin{equation}
\label{errorfct}\frac{1}{2}\erfc\left(\frac{\theta-x}{\sqrt{2\sigma^2}}\right)
\end{equation}
where $\sigma$ is the parameter quantifying the noise (figure ?) %\ref{idealizedactivation}). \notejb{$\sigma$ quantifies the noise in units of the stimulus!!! THis is why this approach might work!}
A neuron with a $\sigma$ of 0 would be a perfect thresholding mechanism. Firing probability for all inputs below the threshold is 0, and firing probability for all inputs above is 1. If $\sigma$ is greater than 0, a neuron with such an activation curve will fire even for some signals below the firing threshold, while it will sometimes not fire for inputs above the firing threshold. For large values of $\sigma$ the activation curve becomes flatter, meaning the probability for inputs below the theshold eliciting a spike is large and the probability that an input above the threshold does not lead to firing is also large. The firing behaviour of such a cell is influenced less by the signal, which indicates noisiness.
However, for strong noise $(>10^{-2} \frac{mV^2}{Hz})$, results are not monotonous anymore. This happens at a point where $\sigma$ becomes large. Therefore, we excluded all values of the unit-less \(\sigma\) larger than two from the following analyses.
\subsection*{Methodology}
The signal was binned according to its amplitude. The result is a discrete Gaussian distribution around 0mV, the mean of the signal, as is expected from the way the signal was created.
After accounting for time delays in signal processing, we make a histogram which contains the distribution of spikes according to signal amplitude.
This histogram is then normalized by the distribution of the signal.
The result is another histogram, where values are firing frequencies for each signal value. Because those frequencies are just firing probabilities multiplied with equal time steps, we can fit a Gaussian error function to those probabilities.
\subsection*{Simulation}
To confirm that the $\sigma$ parameter estimated from the fit is indeed a good measure for the noisiness, we validated it against D, the noise parameter from the simulations. We find that there is a strictly monotonous relationship between the two for different sets of simulation parameters.
%Other parameters often used to determine noisiness (citations) such as the variance of the spike PSTH, the coefficient of variation (CV) of the interspike interval are not as useful. In figure \ref{noiseparameters} we see why. The variance of the psth is not always monotonous in D and is very flat for low values of D.
%describe what happens to the others
%check Fano-factor maybe?
We tried several different bin sizes (30 to 300 bins) and spike widths. There was little difference between the different parameters (see appendix).
\section*{-----------------------}
%We can use $\sigma$ instead of D*firing_rate: $\sigma$ makes it ind. of fr!!
\subsection*{Electrophysiology}
We find that the fits match the experimental data very well (figure \ref{sigmafits}). For very weak and very strong inputs, the firing rates themselves become noisy, because the signal only assumes those values rarely. This is especially noticeable for strong inputs, as there are more spikes there, and therefore large fluctuations, while there is very little spiking anyway for weak inputs.
We find that the fitted plots match the experimental data very well (figure \ref{sigmafits}). For very weak and very strong inputs, the firing rates themselves become noisy, because the signal only assumes those values rarely. This is especially noticeable for strong inputs, as there are more spikes there, and therefore large fluctuations, while there is very little spiking anyway for weak inputs.
% fish_raster.py on oilbird for the eventplot
% instructions.txt enth\"alt python-Befehle um Verteilungen und scatter zu rekonstruieren
@ -747,17 +720,121 @@ Indeed, if results are not averaged and single cells are considered, we find tha
\label{ephys_sigma}
\end{figure}
%The value of $\sigma$ is not signal independent. The same cell can have different values for $\sigma$ for different input signals.
%The value of $\sigma$ is not signal independent. The same cell can have different values for $\sigma$ for different input signals.
\subsection*{Results}
Figure \ref{fig:ex_data} A,B and C show three examples for coherence from intracellular
measurements in \lepto\. Each cell was exposed to up to 128 repetitions of the
same signal. The response was then averaged over different numbers of trials to
simulate different population sizes of homogeneous cells. We can see that an increase
in population size leads to higher coherence. Similar to what we saw in the simulations,
around the average firing rate of the cell (marked by the red vertical lines), coherence
decreases sharply. We then aggregated the results for 31 different cells (50 experiments total,
as some cells were presented with the stimulus more than once).
Figure \ref{ex_data} D shows that the increase is largest inside the
high frequency intervals. As we could see in our simulations (figures \ref{fig:popsizenarrow15} C
and \ref{fig:popsizenarrow10} C), the ratio of coding fraction in a large population
to the coding fraction in a single cell is larger for higher frequencies.
%simulation plots are from 200hz/nice coherence curves.ipynb
\begin{figure}
\centering
\includegraphics[width=0.49\linewidth]{img/fish/coherence_example.pdf}
\includegraphics[width=0.49\linewidth]{img/fish/coherence_example_narrow.pdf}
\includegraphics[width=0.49\linewidth]{{img/coherence/broad_coherence_15.0_1.0_different_popsizes_0.001}.pdf}
\includegraphics[width=0.49\linewidth]{{img/coherence/coherence_15.0_0.5_narrow_both_different_popsizes_0.001}.pdf}
\label{fig:ex_data}
\caption{A,B,C: examples of coherence in the p-Units of \lepto. Each plot shows
the coherence of the response of a single cell to a stimulus for different numbers of trials.
Like in the simulations, increased population sizes lead to a higher coherence.
D: Encoding of higher frequency intervals profits more from an increase in
population size than encoding of lower frequency intervals.
The ratio of the coding fraction for the largest number of trials divided by
the coding fraction for a single trial for each of six different frequency
intervals. Shown here are the data for all 50 experiments (31 different cells).
The orange line signifies the median value for all cells. The box
extends over the 2nd and 3rd quartile. }
\end{figure}
\input{sigma}
\subsection{Results}
\begin{figure}
\centering
broad
\includegraphics[width=0.48\linewidth]{img/fish/cf_curves/cfN_broad_0.pdf}
\includegraphics[width=0.48\linewidth]{img/fish/cf_curves/cfN_broad_1.pdf}
\includegraphics[width=0.48\linewidth]{img/fish/cf_curves/cfN_broad_2.pdf}
\includegraphics[width=0.48\linewidth]{img/fish/cf_curves/cfN_broad_3.pdf}
\end{figure}
%box_script.py, quot_sigma() und quot_sigma_narrow()
\begin{figure}
\centering
broad
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_broad_0_50.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_broad_50_100.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_broad_100_150.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_broad_150_200.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_broad_200_250.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_broad_250_300.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_broad_0_50.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_broad_50_100.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_broad_100_150.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_broad_150_200.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_broad_200_250.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_broad_250_300.pdf}
narrow
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_narrow_0_50.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_narrow_50_100.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_narrow_150_200.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_narrow_250_300.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/sigma_cf_quot_narrow_350_400.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_narrow_0_50.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_narrow_50_100.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_narrow_150_200.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_narrow_250_300.pdf}
\includegraphics[width=0.16\linewidth]{img/fish/scatter/check_fr_quot_narrow_350_400.pdf}
\end{figure}
\begin{figure}
\centering
\includegraphics[width=0.4\linewidth]{img/fish/diff_box.pdf}
\includegraphics[width=0.4\linewidth]{img/fish/diff_box_narrow.pdf}
\includegraphics[width=0.4\linewidth]{img/relative_coding_fractions_box.pdf}
\notedh{needs figure 3.6 from yue and equivalent}
\end{figure}
\begin{figure}
\includegraphics[width=0.49\linewidth]{img/fish/ratio_narrow.pdf}
\includegraphics[width=0.49\linewidth]{img/fish/broad_ratio.pdf}
\label{freq_delta_cf}
\caption{This is about frequency and how it determines $delta_cf$. In other paper I have used $quot_cf$.}
\end{figure}
\subsection{Discussion}
\input{fish_bands}
We also confirmed that the results from the theory part of the paper play a role in a
real world example. Inside the brain of the weakly electric fish
\textit{Apteronotus leptorhynchus} pyramidal cells in different areas
are responsible for encoding different frequencies. In each of those areas,
cells integrate over different numbers of the same receptor cells.
Artificial populations consisting of different trials of the same receptor cell
show what we have seen in our simulations: Larger populations help
especially with the encoding of high frequency signals. These results
are in line with what is known about the pyramidal cells of \lepto:
The cells which encode high frequency signals best are the cells which
integrate over the largest number of neurons.
\section{Discussion: Combining experiment and simulation}