@staticmethod
def to_html(pio, personaliseResultWrapper):
    """ Renders results to an HTML table, fundamentally flawed at this point as there is no support for blends with more then 2 models"""
    html = '<h2>Results for group {label}</h2>'.format(label=
        personaliseResultWrapper.experiment['abvariant']['label'])
    html += '<table>'
    html += (
        '<tr><th>model1.name</th><th>model1.weight</th><th>model1.score</th><th>model2.name</th><th>model2.weight</th><th>model2.score</th><th>wscore</th><th>value</th></tr>'
        )
    for res in personaliseResultWrapper._results:
        html += '<tr>'
        if len(res.components) == 0:
            html += (
                '<td></td><td></td><td></td><td></td><td></td><td></td><td>{score}</td><td>{url}</td>'
                .format(score=res.fscore, url=res.target['value']['url']))
        elif len(res.components) == 1:
            html += (
                '<td>{0}</td><td>{1}</td><td>{2:.2f}</td><td></td><td></td><td></td><td>{3}</td><td>{4}</td>'
                .format(res.components[0]['model']['name'], res.components[
                0]['weight'], res.components[0]['cscore'], res.fscore, res.
                target['value']['url']))
        elif len(res.components) == 2:
            html += (
                '<td>{0}</td><td>{1}</td><td>{2:.2f}</td><td>{3}</td><td>{4}</td><td>{5:.2f}</td><td>{6}</td><td>{7}</td>'
                .format(res.components[0]['model']['name'], res.components[
                0]['weight'], res.components[0]['cscore'], res.components[1
                ]['model']['name'], res.components[1]['weight'], res.
                components[1]['cscore'], res.fscore, res.target['value'][
                'url']))
        else:
            print(
                "we don't support to_html() for results of blends with more then two models"
                )
            pass
        html += '</tr>'
    return html
