Page 1 of 1
Excitatory and inhibitory contributions
Posted: Fri May 11, 2007 8:34 am
by Sandrine
Hello,
I have a network of 150 neurons. Some are excitatory neurons, some are inhibitory neurons and i did connections.
And, what i would like to do is to sum all the membrane potentials generated by excitatory neurons and all the membrane potentials generated by inhibitory neurons, in order to find the respective contributions of excitatory and inhibitory neurons in my network.
Is it possible to plot the resulting curves?
Thanks a lot for your help,
Sandrine.
Posted: Fri May 11, 2007 9:28 am
by ted
Of course. Anything that has a numerical value can be plotted. Read about the Graph and
Vector classes' methods in the Programmer's Reference. You'll probably want to use the
Vector plot() method.
Posted: Mon May 14, 2007 3:59 am
by Sandrine
Yes, it should help me, thanks.
But first i want to sum the different contributions of excitation and inhibition.
Is there a simple way to do this?
Posted: Mon May 14, 2007 9:26 am
by ted
All things are possible through programming. However, human language is imprecise.
What exactly does this statement mean?
Sandrine wrote:i want to sum the different contributions of excitation and inhibition.
Do you want
SUMMA v
over all excitatory neurons
or
SUMMA i
over all excitatory synapses
?
If the former, are your model cells multicompartment or single compartment?
Posted: Mon May 14, 2007 12:00 pm
by Sandrine
Ok i want
SUMMA v
over all excitatory neurons
(and even if is not necessary then, my model cells are multicompartment)
Posted: Mon May 14, 2007 9:09 pm
by ted
Code: Select all
want
SUMMA v
over all excitatory neurons
One simple-minded approach: use the Vector class's record method to capture the somatic
membrane potential trajectories, and at the end of a run use the add method to add them up.
Assuming that the model cells are instances of a class, and that the objrefs for all instances
of excitatory neurons have been appended to a List called ecells,
This setup code creates the Vectors
Code: Select all
objref vrecs, tobj
vrecs = new List()
for i=0,ecells.count()-1 {
tobj = new Vector()
ecells.o(i).soma tobj.record(&v(0.5))
vrecs.append(tobj)
}
This defines proc myrun which, when invoked, will run a simulation and calculate a Vector whose
elements are the time course of the sum of somatic membrane potentials.
Code: Select all
objref vsum
proc postprocess() { local i
vsum = vrecs.o(0).c
// assumes that there is more than one excitatory neuron
for i=1,vrecs.count()-1 vsum.add(vrecs.o(i))
}
proc myrun() {
run()
postprocess()
}
Posted: Fri May 18, 2007 4:10 am
by Sandrine
Thanks again for your help! It works.
Sandrine.
Posted: Tue Jun 05, 2007 4:44 am
by Sandrine
An other little question....
How can i now integrate the response of the membrane potential (Vm) over all the membrane area?
I saw the "integral" method in the documentation, but not over a surface.
Thank you,
Sandrine.
Posted: Tue Jun 05, 2007 9:03 am
by ted
If all neurons are single compartment models,
Code: Select all
objref vrecs, tobj, areavec
vrecs = new List()
areavec = new Vector()
for i=0,ecells.count()-1 {
tobj = new Vector()
ecells.o(i).soma {
tobj.record(&v(0.5))
vrecs.append(tobj)
areavec.append(area(0.5))
}
}
proc postprocess() { local i
vsum = vrecs.o(0).c.mul(areavec.x[0])
// assumes that there is more than one excitatory neuron
for i=1,vrecs.count()-1 vsum.add(vrecs.o(i).c.mul(areavec.x[i])
}
Posted: Tue Jun 05, 2007 9:22 am
by Sandrine
Unfortunately i have multicompartmental models of neurons. Actually, i have 10 compartments per neuron.
Maybe i can do the first part of the code for each compartment:
objref vrecs, tobj, areavec
vrecs = new List()
areavec = new Vector()
for i=0,ecells.count()-1 {
tobj = new Vector()
ecells.o(i).soma { //idem for axon and for dend
tobj.record(&v(0.5))
vrecs.append(tobj)
areavec.append(area(0.5))
}
}
is there a better way to do it?
Posted: Tue Jun 05, 2007 9:43 am
by Sandrine
with SectionList()??
Posted: Fri Jun 08, 2007 3:43 pm
by ted
Approaches based on recording and manipulating vectors for every
compartment of every cell will scale poorly as the number of cells increases.
It is time to step back from details of implementation, and ask what you are
trying to do.