TrakEM2 Scripting

Revision as of 21:35, 28 October 2009 by Albertcardona (talk | contribs) (Starting ...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Examples in Jython

Get the instance of a selected image

>>> p = Display.getFront().getActive()
>>> print p
090504_0314_ex0768.mrc z=0.0 #67398


Obtain the ImagePlus of a selected image

>>> p = Display.getFront().getActive()
>>> imp = p.getImagePlus()
>>> print imp.width, imp.height
2048 2048