[AstroPy] numpy.arange and quantities
Leonard Burtscher
burtscher at strw.leidenuniv.nl
Tue Nov 29 04:19:23 EST 2016
OK, I see. Have you seen the discussion here?
https://github.com/astropy/astropy/wiki/Quantity-Arrays
Seems to be a known problem, but I'm don't know if it has been solved.
> Am 29.11.2016 um 10:16 schrieb Ole Streicher <astropy at liska.ath.cx>:
>
> Leonard Burtscher <burtscher at strw.leidenuniv.nl> writes:
>> r=np.arange(0,9,0.1)*u.km
>>
>> works.
>
> Sure. But the quantities are already given. I could convert them to
> numbers first (with a random unit), like
>
> np.arange(z0/u.m, z1/u.m, dz/u.m) * u.m
>
> But this looks really ugly.
>
> Cheers
>
> Ole
> _______________________________________________
> AstroPy mailing list
> AstroPy at scipy.org
> https://mail.scipy.org/mailman/listinfo/astropy
--
http://strw.leidenuniv.nl/~burtscher
More information about the AstroPy
mailing list