This is documentation for an old release of NumPy (version 1.6.0). Read this page in the documentation of the latest stable release (version > 1.17).
Return a string representation of a number in the given base system.
Parameters : | number : int
base : int, optional
padding : int, optional
|
---|---|
Returns : | out : str
|
See also
Examples
>>> np.base_repr(5)
'101'
>>> np.base_repr(6, 5)
'11'
>>> np.base_repr(7, base=5, padding=3)
'00012'
>>> np.base_repr(10, base=16)
'A'
>>> np.base_repr(32, base=16)
'20'