how to calculate section area

Managing anatomically complex model cells with the CellBuilder. Importing morphometric data with NEURON's Import3D tool or Robert Cannon's CVAPP. Where to find detailed morphometric data.
Post Reply
fabien tell
Posts: 49
Joined: Mon Mar 25, 2013 1:36 pm
Location: france
Contact:

how to calculate section area

Post by fabien tell »

Hello,
I'd like to calculate areas of different sections. I've read the documentation and searched through the forum but it remains unclear to me.

How do I use the the area () command ?

I loaded a hoc file with full morphology then

I tried this :

Code: Select all

soma { 
surface= area(0.5)
print surface } 

axon  { 
surface2= area(0.5)
print surface2 } 
It doesn't work

Thanks a lot
ted
Site Admin
Posts: 6287
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: how to calculate section area

Post by ted »

Works for me. After starting NEURON I entered two lines of text and got the expected result.

Code: Select all

oc>create soma
oc>soma { surface = area(0.5)
>	oc>print surface }
157079.63 
oc>
Try it.

What might be happening in your case? Try this:
1. start NEURON
2. load your "hoc file with full morphology"
3. at the oc> prompt execute the command
forall print secname()
just to make sure that the sections exist.
fabien tell
Posts: 49
Joined: Mon Mar 25, 2013 1:36 pm
Location: france
Contact:

Re: how to calculate section area

Post by fabien tell »

Hello Ted,

Actually you're right; it works as it should. I mixed up with section names. Sorry for bothering....

Acting fast is sometimes the enemy of thinking !!!!

Thanks a lot
fabien tell
Posts: 49
Joined: Mon Mar 25, 2013 1:36 pm
Location: france
Contact:

Re: how to calculate section area

Post by fabien tell »

Hello again,

I have a soma : L= 31 diam = 10
So according to I learned at school, the surface of a cylinder S= PI*diam*L (if we neglect the disk surfaces).

With neuron I got :

Code: Select all

oc>soma {print L}
31 
oc>soma {print diam}
10 
oc>soma {print area(0.5)}
324.63124 
By hand I got 3.14*10*31 = 31.4*31= 973.4

What's the problem ?

I have three nseg for the soma, so I guess that the problem since 973.4/324.63 = 3 . How do I get the full area ? I tought I could mutilply by nseg :

Code: Select all

oc>soma {sur= area(0.5)*nseg}
oc>print sur
973.89372 
It works but what about dendrites with tapering , it would overestimate the area ?

Thanks a lot
ted
Site Admin
Posts: 6287
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: how to calculate section area

Post by ted »

totalarea = 0
soma for (x,0) totalarea += area(x)
fabien tell
Posts: 49
Joined: Mon Mar 25, 2013 1:36 pm
Location: france
Contact:

Re: how to calculate section area [SOLVED]

Post by fabien tell »

Thanks a lot
Post Reply