amal wrote:How can we make Ca buffer to come into play only after certain level of cai is attained ?
If you mean "make buffering have a hard threshold," the answer is: that isn't going to happen with a mechanism specified using kinetic scheme notation.
How can we plot CaBuffer (CaBuffer[0],[1],[2] or [3]) with time?
When unsure about syntax for plotting a particular variable, the quick way to find out is make a toy model with just one section, insert the mechanism into it, use the GUI to bring up a graph ("Current axis" or "State axis" would be good for this), then use that graph's "Plot what?" to construct the string by clicking on menus. Avoids typos and syntax errors, and much easier done than said. In the FAQ list see
Q: How do I plot something other than membrane potential?
You'll find a link to the FAQ list at
http://www.neuron.yale.edu/neuron/docs.
Since the variables of interest to you belong to a section, double click on the name of the section in the Plot what? tool's left column, and use the middle and right columns to select exactly what you want.
Two suggestions for your proc addgraph--
First, instead of predeclaring
,use a List
You won't need the ngraph variable.
Second, instead of addexpr use addvar. addexpr will reinterpret the name of the plotted variable at every fadvance, which is absolutely unnecessary.
Your proc addgraph() then becomes
Code: Select all
proc addgraph() { localobj tobj
tobj = new Graph()
glist.append(tobj)
tobj.size(0,tstop,$2,$3)
tobj.addvar($s1,1,1)
graphList[0].append(tobj)
tobj.label($4, $5, $s1)
}