parameters: (a, digits=2)
docstring: _string_from_complex_sigfig(a, digits=2)
  
      This function assumes that "a" is a complex number. It returns "a" as a string
      in which the real and imaginary parts have digits significant digits.
docstring_summary: _string_from_complex_sigfig(a, digits=2)
docstring_tokens: _string_from_complex_sigfig ( a digits = 2 )
function: def _string_from_complex_sigfig(a, digits=2):
      """_string_from_complex_sigfig(a, digits=2)
  
      This function assumes that "a" is a complex number. It returns "a" as a string
      in which the real and imaginary parts have digits significant digits.
      """
      re = to_precision.to_precision(a.real, digits)
      im = to_precision.to_precision(np.abs(a.imag), digits)
      if a.imag >= 0:
          return '{:s}+{:s}j'.format(re, im)
      elif a.imag < 0:
          return '{:s}-{:s}j'.format(re, im)
function_tokens: def _string_from_complex_sigfig ( a , digits = 2 ) : re = to_precision . to_precision ( a . real , digits ) im = to_precision . to_precision ( np . abs ( a . imag ) , digits ) if a . imag >= 0 : return '{:s}+{:s}j' . format ( re , im ) elif a . imag < 0 : return '{:s}-{:s}j' . format ( re , im )