to_astropy_decorator

amuse_util.units.to_astropy_decorator(function=None, \*, arguments=[])[source]

Function decorator to convert inputs to Astropy quantities.

Parameters
functiontypes.FunctionType or None, optional

the function to be decoratored if None, then returns decorator to apply.

argumentslist, optional

arguments to convert integers are indices into arguments strings are names of kw arguments

Returns
wrappertypes.FunctionType

wrapper for function does a few things includes the original function in a method __wrapped__