(d)
return d_mean_ci
Summarizes each list value of dict d into a mean and confidence interval.

  The summarized version of an empty dictionary, is also empty.

  Args:
    d: A dict where each value is a list.

  Returns:
    d_mean_ci: If d is not empty, a dict with the same keys as d but with each
      value which was originally a list replaced with a tuple of the mean of
      that list and the corresponding confidence interval.

  Raises:
    ValueError: The values of d are not lists.
Summarizes each list value of dict d into a mean and confidence interval.
Summarizes each list value of dict d into a mean and confidence interval .
def summarize_values_stats(d):
  """Summarizes each list value of dict d into a mean and confidence interval.

  The summarized version of an empty dictionary, is also empty.

  Args:
    d: A dict where each value is a list.

  Returns:
    d_mean_ci: If d is not empty, a dict with the same keys as d but with each
      value which was originally a list replaced with a tuple of the mean of
      that list and the corresponding confidence interval.

  Raises:
    ValueError: The values of d are not lists.
  """
  if not d:
    return {}

  for v in d.values():
    if not isinstance(v, list):
      raise ValueError('The values of the provided dict are not lists.')

  d_mean_ci = {}
  for k, v in d.items():
    mean = np.mean(v)
    ci = np.std(v) * 1.96 / np.sqrt(len(v))
    d_mean_ci[k] = (mean, ci)
  return d_mean_ci
def summarize_values_stats ( d ) : if not d : return { } for v in d . values ( ) : if not isinstance ( v , list ) : raise ValueError ( 'The values of the provided dict are not lists.' ) d_mean_ci = { } for k , v in d . items ( ) : mean = np . mean ( v ) ci = np . std ( v ) * 1.96 / np . sqrt ( len ( v ) ) d_mean_ci [ k ] = ( mean , ci ) return d_mean_ci