[yt-dev] Issue #561: SlicePlot set_width() does not work with unitful arguments (yt_analysis/yt)

J.S. Oishi issues-reply at bitbucket.org
Wed May 8 09:43:10 PDT 2013


New issue 561: SlicePlot set_width() does not work with unitful arguments
https://bitbucket.org/yt_analysis/yt/issue/561/sliceplot-set_width-does-not-work-with

J.S. Oishi:

The documentation for set_width() says that it can take an argument using a tuple (10, 'cm') for each x component of the x-y plot, for example:

sp = SlicePlot(pf, "z", "MagneticPressure")
sp.set_width((25.6, 'cm'), (10, 'cm'))

However, this returns a slice with the width unchanged. Using code units, e.g.:

sp = SlicePlot(pf, "z", "MagneticPressure")
sp.set_width(1, 0.4)

works fine.





More information about the yt-dev mailing list