code: def mean_cl_normal(series, confidence_interval=0.95):
      """
      Mean with confidence interval assuming normal distribution
  
      Credit: from http://stackoverflow.com/a/15034143
  
      Parameters
      ----------
      series : pandas.Series
          Values
      confidence_interval : float
          Confidence interval in the range (0, 1).
      """
      import scipy.stats as stats
  
      a = np.asarray(series)
      m = np.mean(a)
      se = stats.sem(a)
      h = se * stats.t._ppf((1 + confidence_interval) / 2, len(a) - 1)
      return pd.DataFrame({"y": [m], "ymin": m - h, "ymax": m + h})
  
file_path: plotnine/plotnine/stats/stat_summary.py
imports: import numpy
  import pandas
  from .._utils import get_valid_kwargs, uniquecols
  from ..doctools import document
  from ..exceptions import PlotnineError
  from .stat import stat
label_desc: Use image node_id 3 for calling a global function with example usage: mean_cl_normal(series, confidence_interval) and returns: pd