-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathlibrary.g
62 lines (59 loc) · 1.29 KB
/
library.g
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//genesis
//
// library.g - creating library of ionic chanels and a prototype cell
function make_channels(path)
str path
pushe {path}
make_Na
make_shNa
make_Kt
make_Ks
make_CaN
make_CaN_pool
make_KCaN
make_CaL
make_CaLVA
make_Na_pool
make_KNa
make_Na_slow_pool
make_KNa_slow
make_Glyc
make_AMPA
make_NMDA
make_CaNMDA
make_CaNMDA_pool
make_KCaNMDA
pope
end
function make_spiker
if({exists spike})
return
end
str chanpath = "spike"
create spikegen {chanpath}
setfield {chanpath} thresh -40e-3 abs_refract 1e-3 output_amp 1
addmsg . {chanpath} INPUT Vm
end
function make_cell(filename, path)
str filename, path
str chan, comp
if({solver})
readcell {filename} {path} -hsolve
setfield {path} chanmode 1
else
readcell {filename} {path}
end
if({exists {path}/iseg})
pushe {path}/iseg
make_spiker
pope
end
foreach chan ({el {path}/#/NMDA})
comp = {getpath {chan} -head}
deletemsg {chan} 1 -outgoing
end
foreach chan ({el {path}/#/CaNMDA})
comp = {getpath {chan} -head}
deletemsg {chan} 0 -outgoing
end
end