I am very new at programming in hoc language so please bear with me if what I ask feels very basic. I have managed to model a neural cell (single cell in the Ball and Stick configuration, with myelinated compartments and a separate section for the AIS node, but no dendrites). On this single cell, I wish to test several things. One is the conduction velocity changes when I change certain parameters (i.e. capacitance, conductance, etc). To do so however, I need to obtain the characteristics of the Action Potentials (APs) in order to later calculate the conduction velocity. Such characteristics are:
(i) Magnitude of the peak of the spikes at the specified recording location,
(ii) Timing that reaches the peaks,
Personal Approach:
I read about NetCon but this requires to have synaptic inputs, which I don't (stimulation is given via an IClamp point process, at the center of the soma), so I do not think I can use the NetCon.record() method to pick the signal. At least not if I understood the NetCon correctly. Thus, I was considering of using the vector.record() like this:
Code: Select all
stim_pos = 0.5 // stimulation site at the soma with an IClamp
pos1 = 1 // at the soma
pos2 = 1 // at the axon
objref recvol1, rectim1, recvol2, rectim2
proc APstimVT() { // Get voltage AP-value and timing of peak-reaching
// First point
recvol1 = new Vector()
rectim1 = new Vector()
rectim1.record(&t)
soma recvol1.record(&soma.v(pos1),rectim1)
APpeak1 = recvol1.max()
APpeak1_index = recvol1.max_ind()
print "The max voltage is = ", APpeak1, " [mV]"
APpeakTime1 = rectim1.get(APpeak1_index) // has a problem with out-of range values
//APpeakTime1 = rectim1.where(&soma.v(pos1),"==", APpeak1) //expects string value so this does not work
print "The timing of the max voltage is = ", APpeakTime1, " [ms]"
print APpeakTime1
//Second point
recvol2 = new Vector()
rectim2 = new Vector()
rectim2.record(&t)
axon recvol2.record(&axon.v(pos2),rectim2)
APpeak2 = recvol2.max()
APpeak2_index = recvol2.max_ind()
print "The max voltage is = ", APpeak2, " [mV]"
APpeakTime2 = rectim2.get(APpeak2_index) // has a problem with out-of range values
//axon recvol2.where(&axon.v(pos2),"==", APpeak2)
print "The timing of the max voltage is = ", APpeakTime2, " [ms]"
print APpeakTime2
}
run()
APstimVT()
- The maximum value of the voltage is returned as a zero, which is not accurate (from the graph, it seems to be ~22 [mV]). Can it be that the recording location is not the proper one or is it a matter of coding? Can it be that it is not obtaining the total-maximum voltage amplitude, but only a local-maximum that is just the highest one from the sampled values?
- It prints right after the 0 voltage: out of range in user function. This is probably because I have index = -1, which is weird though and I think it is cause I am probably misunderstanding some programming aspects/functions of vectors.
Finally, I believe it is important to mention that I use cvode.active(1) in the beginning of my code cause I noticed I was getting unwanted artifacts before (hence, for better accuracy).
Can someone help please? What am I doing wrong/have misunderstood?
Thank you very much in advance!
Best,