check_if_unit_is_per_solid_angle#
- jdaviz.core.validunits.check_if_unit_is_per_solid_angle(unit)[source]#
Check if a given u.Unit or unit string (that can be converted to a u.Unit object) represents some unit per solid angle.
- Parameters:
- unitstr or u.Unit
Unit object or string representation of unit.
Examples
>>> check_if_unit_is_per_solid_angle('erg / (s cm^2 sr)') True >>> check_if_unit_is_per_solid_angle('erg / s cm^2') False >>> check_if_unit_is_per_solid_angle('Jy * sr^-1') True