![]() Print(tmpstr) // check the command strings before you comment this out Sprint(tmpstr, "g.addexpr(%s, 1)", $o1.object(i).s) ) // this example uses brush 1 for all expects a List of String objrefs as its only arg TmpStr.s = "\"foo\", 1" // name in quotes and color An example that uses bogus variable names: a strdef that is part of the argument that you eventually want to use in before calling your proc, fill the List with String objects, each of which contains or execute load_file("nrngui.hoc") or load_file("noload.hoc") in stdlib.hoc, which is automatically loaded if you run nrngui, TmpStr = new String() // an object wrapper for strdef-see begintemplate String The single argument form maps a view in which the aspect ratio between x and y axes is always 1. The placement of the window with respect to the screen is intended to be precise and is with respect to pixel coordinates where 0,0 is the top left corner of the screen. m stands for model coordinates within the window, w stands for screen coordinates for placement and size of the window. view(mleft, mbottom, mwidth, mheight, wleft, view function I figure out that this does also set coordinates for the graph axis as well as setting the window coordinates relative to the display field overall: The plotVoltage() command below was provided to me by another Neuron computational group as part of a hoc file that specifies some common procedures used in a typical simulation. I can see that I should be using the newPlotV() command rather than that for current, and how to specify the axis limits if I want to change them from the default axis settings. Thank you for this detailed answer to my plotting question. When adaptive integration ("CVODE") is used, all variables are computed to the sameĭegree of accuracy at identical times, and all "Voltage axis," "Current axis," and "StateĪxis" graphs plot their variables at identical values of t. This means that there isn't a specific time in the interval from (t - 0.5*dt) to (t + 0.5*dt)Īt which voltages, currents, and states are first order correct-they're equally local error of the solution is proportional to dt, the size of the time "But doesn't this mess up the accuracy of current and state graphs when the defaultīackward Euler method is used?" No, because backward Euler is only first orderĪccurate in time, i.e. ![]() By plotting voltages in Voltage axis graphs, currents in Current axis graphs,Īnd states in State axis graphs, the plotted points preserve second order accuracy in Secondorder), voltages will be second order correct at integral multiples of dt, butĬurrents and states will be second order correct half a time step earlier or later, The reason for this is that, if you use NEURON's Crank-Nicholson integrator (byĪssigning secondorder = 2 - see the Programmer's Reference documentation of the current value of t, but for graphList the xĬoordinates are t - 0.5*dt, and for graphList the x coords are t + 0.5*dt. Is used, graphList,, and differ in the x coordinates used for plotted points. Three graphLists, so that they will be automatically updated during simulation execution.Īs noted at the end of chapter 7 in The NEURON Book, when fixed time step integration Graphs spawned by newPlotV(), newPlotI(), and newPlotS() are appended to one of Print "myPlotV error-first argument must be smaller than second argument" "dropdown menu" that appears when you click on the toolbar's Graph button: ![]() In fact, here is the code in stdrun.hoc that generates the Nrn/share/nrn/lib/hoc under UNIX / Linux / OS X, or c:\nrnxx\lib\hoc under MSWin (where NewPlotV() and newPlotS(), are defined in stdrun.hoc, which you will find in Toolbar to spawn a new "Current axis" graph. NewPlotI() is the very procedure that is executed when you use the NEURON Main Menu Is that something youįound somewhere in ModelDB or on the WWW? It doesn't seem to be built into NEURON.īack to the main thread of this discussion. That will let you specify whatever y axis scaling you like.Īn aside: I'm not aware of any procedure called plotVoltage(). The bad news is no, but the good news is that it's easy to make your own procedure Is there a way to set the y-axis scaling with the first newPlotI procedure? However, if I use the plot command below for the soma only, then the y-axis is scaled automatically. I use the following command to plot voltage in soma and a dendritic compartment but it the y-axis is set at -1 to 1.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |