def trunk_origin_azimuths(nrn, neurite_type=NeuriteType.all):
neurite_filter = is_type(neurite_type)<EOL>nrns = neuron_population(nrn)<EOL>def _azimuth(section, soma):<EOL><INDENT>'''<STR_LIT>'''<EOL>vector = morphmath.vector(section[<NUM_LIT:0>], soma.center)<EOL>return np.arctan2(vector[COLS.Z], vector[COLS.X])<EOL><DEDENT>return [_azimuth(s.root_node.points, n.soma)<EOL>for n in nrns<EOL>for s in n.neurites if neurite_filter(s)]<EOL>
Get a list of all the trunk origin azimuths of a neuron or population

    The azimuth is defined as Angle between x-axis and the vector
    defined by (initial tree point - soma center) on the x-z plane.

    The range of the azimuth angle [-pi, pi] radians