prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Add badges for "highly skewed", "zeros"
  I enjoy the badges on the report and am happy to submit a PR for this if it isn't being worked on elsewhere.
  
  </issue>
  <code>
  [start of pandas_profiling/templates.py]
  1 # coding=UTF-8
  2 
  3 '''This file contains all templates used for generating the HTML profile report'''
  4 
  5 from jinja2 import Environment, PackageLoader
  6 
  7 # Initializing Jinja
  8 pl = PackageLoader('pandas_profiling', 'templates')
  9 jinja2_env = Environment(lstrip_blocks=True, trim_blocks=True, loader=pl)
  10 
  11 # Mapping between template name and file
  12 templates = {'freq_table_row': 'freq_table_row.html',
  13              'mini_freq_table_row': 'mini_freq_table_row.html',
  14              'freq_table': 'freq_table.html',
  15              'mini_freq_table': 'mini_freq_table.html',
  16              'row_num': 'row_num.html',
  17              'row_date': 'row_date.html',
  18              'row_cat': 'row_cat.html',
  19              'row_bool': 'row_bool.html',
  20              'row_corr': 'row_corr.html',
  21              'row_recoded': 'row_recoded.html',
  22              'row_const': 'row_const.html',
  23              'row_unique': 'row_unique.html',
  24              'overview': 'overview.html',
  25              'sample': 'sample.html',
  26              'base': 'base.html',
  27              'wrapper': 'wrapper.html'
  28              }
  29 
  30 # Mapping between row type and var type
  31 var_type = {'NUM': 'Numeric',
  32             'DATE': 'Date',
  33             'CAT': 'Categorical',
  34             'UNIQUE': 'Categorical, Unique',
  35             'BOOL': 'Boolean',
  36             'CONST': 'Constant',
  37             'CORR': 'Highly correlated',
  38             'RECODED': 'Recoded'
  39             }
  40 
  41 
  42 def template(template_name):
  43     """Return a jinja template ready for rendering. If needed, global variables are initialized.
  44 
  45     Parameters
  46     ----------
  47     template_name: str, the name of the template as defined in the templates mapping
  48 
  49     Returns
  50     -------
  51     The Jinja template ready for rendering
  52     """
  53     globals = None
  54     if template_name.startswith('row_'):
  55         # This is a row template setting global variable
  56         globals = dict()
  57         globals['vartype'] = var_type[template_name.split('_')[1].upper()]
  58     return jinja2_env.get_template(templates[template_name], globals=globals)
  59 
  60 
  61 # mapping between row type and template name
  62 row_templates_dict = {'NUM': template('row_num'),
  63                       'DATE': template('row_date'),
  64                       'DISCRETE': template('row_num'),
  65                       'CAT': template('row_cat'),
  66                       'BOOL': template('row_bool'),
  67                       'UNIQUE': template('row_unique'),
  68                       'CONST': template('row_const'),
  69                       'CORR': template('row_corr'),
  70                       'RECODED': template('row_recoded')
  71                       }
  72 
  73 # The number of column to use in the display of the frequency table according to the category
  74 mini_freq_table_nb_col = {'CAT': 6, 'BOOL': 3}
  75 
  76 messages = dict()
  77 messages['CONST'] = u'{0[varname]} has constant value {0[mode]} <span class="label label-primary">Rejected</span>'
  78 messages['CORR'] = u'{0[varname]} is highly correlated with {0[correlation_var]} (ρ = {0[correlation]}) <span class="label label-primary">Rejected</span>'
  79 messages['RECODED'] = u'{0[varname]} is a recoding of {0[correlation_var]} <span class="label label-primary">Rejected</span>'
  80 messages['HIGH_CARDINALITY'] = u'{varname} has a high cardinality: {0[distinct_count]} distinct values  <span class="label label-warning">Warning</span>'
  81 messages['n_duplicates'] = u'Dataset has {0[n_duplicates]} duplicate rows <span class="label label-warning">Warning</span>'
  82 messages['skewness'] = u'{varname} is highly skewed (γ1 = {0[skewness]})'
  83 messages['p_missing'] = u'{varname} has {0[n_missing]} / {0[p_missing]} missing values <span class="label label-default">Missing</span>'
  84 messages['p_infinite'] = u'{varname} has {0[n_infinite]} / {0[p_infinite]} infinite values <span class="label label-default">Infinite</span>'
  85 messages['p_zeros'] = u'{varname} has {0[n_zeros]} / {0[p_zeros]} zeros'
  86 
  87 message_row = u'<li>{message}</li>'
  88
  [end of pandas_profiling/templates.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/pandas_profiling/templates.py b/pandas_profiling/templates.py
  --- a/pandas_profiling/templates.py
  +++ b/pandas_profiling/templates.py
  @@ -79,9 +79,9 @@
   messages['RECODED'] = u'{0[varname]} is a recoding of {0[correlation_var]} <span class="label label-primary">Rejected</span>'
   messages['HIGH_CARDINALITY'] = u'{varname} has a high cardinality: {0[distinct_count]} distinct values  <span class="label label-warning">Warning</span>'
   messages['n_duplicates'] = u'Dataset has {0[n_duplicates]} duplicate rows <span class="label label-warning">Warning</span>'
  -messages['skewness'] = u'{varname} is highly skewed (γ1 = {0[skewness]})'
  +messages['skewness'] = u'{varname} is highly skewed (γ1 = {0[skewness]})  <span class="label label-info">Skewed</span>'
   messages['p_missing'] = u'{varname} has {0[n_missing]} / {0[p_missing]} missing values <span class="label label-default">Missing</span>'
   messages['p_infinite'] = u'{varname} has {0[n_infinite]} / {0[p_infinite]} infinite values <span class="label label-default">Infinite</span>'
  -messages['p_zeros'] = u'{varname} has {0[n_zeros]} / {0[p_zeros]} zeros'
  +messages['p_zeros'] = u'{varname} has {0[n_zeros]} / {0[p_zeros]} zeros <span class="label label-info">Zeros</span>'
   
   message_row = u'<li>{message}</li>'
  
verification_info: {"golden_diff": "diff --git a/pandas_profiling/templates.py b/pandas_profiling/templates.py\n--- a/pandas_profiling/templates.py\n+++ b/pandas_profiling/templates.py\n@@ -79,9 +79,9 @@\n messages['RECODED'] = u'{0[varname]} is a recoding of {0[correlation_var]} <span class=\"label label-primary\">Rejected</span>'\n messages['HIGH_CARDINALITY'] = u'{varname} has a high cardinality: {0[distinct_count]} distinct values  <span class=\"label label-warning\">Warning</span>'\n messages['n_duplicates'] = u'Dataset has {0[n_duplicates]} duplicate rows <span class=\"label label-warning\">Warning</span>'\n-messages['skewness'] = u'{varname} is highly skewed (\u03b31 = {0[skewness]})'\n+messages['skewness'] = u'{varname} is highly skewed (\u03b31 = {0[skewness]})  <span class=\"label label-info\">Skewed</span>'\n messages['p_missing'] = u'{varname} has {0[n_missing]} / {0[p_missing]} missing values <span class=\"label label-default\">Missing</span>'\n messages['p_infinite'] = u'{varname} has {0[n_infinite]} / {0[p_infinite]} infinite values <span class=\"label label-default\">Infinite</span>'\n-messages['p_zeros'] = u'{varname} has {0[n_zeros]} / {0[p_zeros]} zeros'\n+messages['p_zeros'] = u'{varname} has {0[n_zeros]} / {0[p_zeros]} zeros <span class=\"label label-info\">Zeros</span>'\n \n message_row = u'<li>{message}</li>'\n", "issue": "Add badges for \"highly skewed\", \"zeros\"\nI enjoy the badges on the report and am happy to submit a PR for this if it isn't being worked on elsewhere.\n", "before_files": [{"content": "# coding=UTF-8\n\n'''This file contains all templates used for generating the HTML profile report'''\n\nfrom jinja2 import Environment, PackageLoader\n\n# Initializing Jinja\npl = PackageLoader('pandas_profiling', 'templates')\njinja2_env = Environment(lstrip_blocks=True, trim_blocks=True, loader=pl)\n\n# Mapping between template name and file\ntemplates = {'freq_table_row': 'freq_table_row.html',\n             'mini_freq_table_row': 'mini_freq_table_row.html',\n             'freq_table': 'freq_table.html',\n             'mini_freq_table': 'mini_freq_table.html',\n             'row_num': 'row_num.html',\n             'row_date': 'row_date.html',\n             'row_cat': 'row_cat.html',\n             'row_bool': 'row_bool.html',\n             'row_corr': 'row_corr.html',\n             'row_recoded': 'row_recoded.html',\n             'row_const': 'row_const.html',\n             'row_unique': 'row_unique.html',\n             'overview': 'overview.html',\n             'sample': 'sample.html',\n             'base': 'base.html',\n             'wrapper': 'wrapper.html'\n             }\n\n# Mapping between row type and var type\nvar_type = {'NUM': 'Numeric',\n            'DATE': 'Date',\n            'CAT': 'Categorical',\n            'UNIQUE': 'Categorical, Unique',\n            'BOOL': 'Boolean',\n            'CONST': 'Constant',\n            'CORR': 'Highly correlated',\n            'RECODED': 'Recoded'\n            }\n\n\ndef template(template_name):\n    \"\"\"Return a jinja template ready for rendering. If needed, global variables are initialized.\n\n    Parameters\n    ----------\n    template_name: str, the name of the template as defined in the templates mapping\n\n    Returns\n    -------\n    The Jinja template ready for rendering\n    \"\"\"\n    globals = None\n    if template_name.startswith('row_'):\n        # This is a row template setting global variable\n        globals = dict()\n        globals['vartype'] = var_type[template_name.split('_')[1].upper()]\n    return jinja2_env.get_template(templates[template_name], globals=globals)\n\n\n# mapping between row type and template name\nrow_templates_dict = {'NUM': template('row_num'),\n                      'DATE': template('row_date'),\n                      'DISCRETE': template('row_num'),\n                      'CAT': template('row_cat'),\n                      'BOOL': template('row_bool'),\n                      'UNIQUE': template('row_unique'),\n                      'CONST': template('row_const'),\n                      'CORR': template('row_corr'),\n                      'RECODED': template('row_recoded')\n                      }\n\n# The number of column to use in the display of the frequency table according to the category\nmini_freq_table_nb_col = {'CAT': 6, 'BOOL': 3}\n\nmessages = dict()\nmessages['CONST'] = u'{0[varname]} has constant value {0[mode]} <span class=\"label label-primary\">Rejected</span>'\nmessages['CORR'] = u'{0[varname]} is highly correlated with {0[correlation_var]} (\u03c1 = {0[correlation]}) <span class=\"label label-primary\">Rejected</span>'\nmessages['RECODED'] = u'{0[varname]} is a recoding of {0[correlation_var]} <span class=\"label label-primary\">Rejected</span>'\nmessages['HIGH_CARDINALITY'] = u'{varname} has a high cardinality: {0[distinct_count]} distinct values  <span class=\"label label-warning\">Warning</span>'\nmessages['n_duplicates'] = u'Dataset has {0[n_duplicates]} duplicate rows <span class=\"label label-warning\">Warning</span>'\nmessages['skewness'] = u'{varname} is highly skewed (\u03b31 = {0[skewness]})'\nmessages['p_missing'] = u'{varname} has {0[n_missing]} / {0[p_missing]} missing values <span class=\"label label-default\">Missing</span>'\nmessages['p_infinite'] = u'{varname} has {0[n_infinite]} / {0[p_infinite]} infinite values <span class=\"label label-default\">Infinite</span>'\nmessages['p_zeros'] = u'{varname} has {0[n_zeros]} / {0[p_zeros]} zeros'\n\nmessage_row = u'<li>{message}</li>'\n", "path": "pandas_profiling/templates.py"}]}