code: def probit(s: "Series", error: str = "warn") -> "Series":
      """Transforms the Series via the inverse CDF of the Normal distribution.
  
      Each value in the series should be between 0 and 1. Use `error` to
      control the behavior if any series entries are outside of (0, 1).
  
      Examples:
          >>> import pandas as pd
          >>> import janitor
          >>> s = pd.Series([0.1, 0.5, 0.8], name="numbers")
          >>> s.probit()
          0   -1.281552
          1    0.000000
          2    0.841621
          dtype: float64
  
      Args:
          s: Input Series.
          error: Determines behavior when `s` is outside of `(0, 1)`.
              If `'warn'` then a `RuntimeWarning` is thrown. If `'raise'`, then
              a `RuntimeError` is thrown. Otherwise, nothing is thrown and
              `np.nan` is returned for the problematic entries.
  
      Raises:
          RuntimeError: When there are problematic values
              in the Series and `error='raise'`.
  
      Returns:
          Transformed Series
      """
      import numpy as np
      import pandas as pd
      import scipy
  
      s = s.copy()
      outside_support = (s <= 0) | (s >= 1)
      if (outside_support).any():
          msg = (
              f"{outside_support.sum()} value(s) are outside of (0, 1)"
          )
          if error.lower() == "warn":
              warnings.warn(msg, RuntimeWarning)
          if error.lower() == "raise":
              raise RuntimeError(msg)
          else:
              pass
      s[outside_support] = np.nan
      with np.errstate(all="ignore"):
          out = pd.Series(scipy.stats.norm.ppf(s), index=s.index)
      return out
  
file_path: pyjanitor/janitor/math.py
imports: import warnings
  from typing import TYPE_CHECKING, Tuple
  import pandas_flavor
label_desc: Use image node_id 7 for calling a global function with example usage: probit(s, error) and returns: out