[AstroPy] equivalent routine to IDL Astronomy Library lineid_plot

Prasanth oneaufs@gmail....
Fri Sep 16 10:02:43 CDT 2011


My attempt at implementing the lineid_plot.pro algorithm is available at
http://github.com/phn/lineid_plot <https://github.com/phn/lineid_plot>.

The automatic layout calculation is identical to that in the IDL procedure.
But I
have tried to make use of the annotate feature provided by Matplotlib for
the rest of the

I don't have access to IDL and hence couldn't properly explore the working
the IDL code. GDL can't run the code.

After implementing the layout calculations, the rest of the code,
surprisingly, turns out
to be not difficult to write at all. This probably means that I am blind to
obvious problems!

Feedback will be greatly appreciated.


On Wed, Aug 24, 2011 at 8:49 PM, Jonathan Slavin <jslavin@cfa.harvard.edu>wrote:

> If I had the time to do that adaptation, I'd certainly do it -- and may
> yet -- but it does depend on a lot of things that are very IDL specific
> such as the character size and plot region, etc.  I think that there are
> some good hints in the discussion on automatically creating enough room
> for tick labels (http://matplotlib.sourceforge.net/faq/howto_faq.html),
> but there's quite a bit more needed than that.
> Jon
> On Wed, 2011-08-24 at 11:48 -0300, Taro Sato wrote:
> > I have my own custom routine to display line identifications at given
> > redshift but it's not smart enough to avoid overlapping; it only
> > alternates the offsets so that adjacent labels won't always overlap.
> > What you have in your example plot is certainly doable with MPL...
> > It's tricky to ensure that labels are readable most of the time but
> > since you know how to approach the problem, why don't you create one
> > and make it available publicly!  If the desired algorithm needed is
> > already coded in the IDL script it shouldn't be too painful.  :D
> --
> ______________________________________________________________
> Jonathan D. Slavin              Harvard-Smithsonian CfA
> jslavin@cfa.harvard.edu         60 Garden Street, MS 83
> phone: (617) 496-7981           Cambridge, MA 02138-1516
>  cell: (781) 363-0035           USA
> ______________________________________________________________
> _______________________________________________
> AstroPy mailing list
> AstroPy@scipy.org
> http://mail.scipy.org/mailman/listinfo/astropy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/astropy/attachments/20110916/d7fcaeaa/attachment.html 

More information about the AstroPy mailing list