12 Apr
2006
12 Apr
'06
1:57 a.m.
Angus McMorland wrote:
Okay, my first reply is to myself, with all the bits I forgot to add.
Make that _some_ of the bits I forgot. Here's the last of them: def xvals(dims): '''Returns a volume with the appropriate x index value in each element.''' evList = ['n.fromfunction( xi, (%d' % dims[0] ] + \ [', %d' % dims[i+1] for i in range( len(dims) - 1 )] + \ [') )'] return eval( ''.join(evList) ) Apologies for the multiple postings. -- Angus McMorland email a.mcmorland@auckland.ac.nz mobile +64-21-155-4906 PhD Student, Neurophysiology / Multiphoton & Confocal Imaging Physiology, University of Auckland phone +64-9-3737-599 x89707 Armourer, Auckland University Fencing Secretary, Fencing North Inc.