def _generate_notebooks_by_category(notebook_object, dict_by_tag):
    """
    Internal function that is used for generation of the page "Notebooks by Category".

    ----------
    Parameters
    ----------
    notebook_object : notebook object
        Object of "notebook" class where the body will be created.

    dict_by_tag : dict
        Dictionary where each key is a tag and the respective value will be a list containing the
        Notebooks (title and filename) that include this tag.

    """

    # ============================ Insertion of an opening text ====================================
    markdown_cell = OPEN_IMAGE

    # == Generation of a table that group Notebooks by category the information about each signal ==
    category_list = list(NOTEBOOK_KEYS.keys())
    tag_keys = list(dict_by_tag.keys())

    markdown_cell += """\n<table id="notebook_list" width="100%">
    <tr>
        <td width="20%" class="center_cell group_by_header_grey"> Category </td>
        <td width="60%" class="center_cell group_by_header"></td>
        <td width="20%" class="center_cell"></td>
    </tr>"""

    for i, category in enumerate(category_list):
        if category != "MainFiles":
            if category.lower() in tag_keys:
                if i == 0:
                    first_border = "color1_top"
                else:
                    first_border = ""


                nbr_notebooks = len(dict_by_tag[category.lower()])
                markdown_cell += "\n\t<tr>" \
                                 "\n\t\t<td rowspan='" + str(nbr_notebooks + 1) + "' class='center_cell open_cell_border_" + str(NOTEBOOK_KEYS[category]) + "'><span style='float:center'><img src='../../images/icons/" + category + ".png' class='icon' style='vertical-align:middle'></span> <span style='float:center' class='color" + str(NOTEBOOK_KEYS[category]) + "'>" + category + "</span></td>" \
                                 "\n\t\t<td class='center_cell color" + str(NOTEBOOK_KEYS[category]) + "_cell " + first_border + "'><span style='float:center'>" + category +  "</span></td>" \
                                 "\n\t\t<td class='center_cell gradient_color" + str(NOTEBOOK_KEYS[category]) + "'></td>" \
                                 "\n\t</tr>"

                notebook_list = dict_by_tag[category.lower()]
                for j, notebook_file in enumerate(notebook_list):
                    if j == len(notebook_list) - 1:
                        last_border = "class='border_cell_bottom_white'"
                    else:
                        last_border = ""

                    split_path = notebook_file.replace("\\", "/").split("/")
                    notebook_name = split_path[-1].split("&")[0]
                    notebook_title = split_path[-1].split("&")[1]
                    markdown_cell += "\n\t<tr " + last_border + ">" \
                                     "\n\t\t<td class='center_cell open_cell_light'> <a href='../" + category + "/" + notebook_name + "'>" + notebook_title + "</a> </td>" \
                                     "\n\t\t<td class='center_cell'> <a href='../" + category + "/" + notebook_name + "'><div class='file_icon'></div></a> </td>" \
                                     "\n\t</tr>"

    markdown_cell += "\n</table>"

    # ============================ Insertion of an introductory text ===============================
    markdown_cell += DESCRIPTION_CATEGORY

    # =================== Insertion of the HTML table inside a markdown cell =======================
    notebook_object["cells"].append(nb.v4.new_markdown_cell(markdown_cell))
def _generate_notebooks_by_category ( notebook_object , dict_by_tag ) : markdown_cell = OPEN_IMAGE category_list = list ( NOTEBOOK_KEYS . keys ( ) ) tag_keys = list ( dict_by_tag . keys ( ) ) markdown_cell += """\n<table id="notebook_list" width="100%">
    <tr>
        <td width="20%" class="center_cell group_by_header_grey"> Category </td>
        <td width="60%" class="center_cell group_by_header"></td>
        <td width="20%" class="center_cell"></td>
    </tr>""" for i , category in enumerate ( category_list ) : if category != "MainFiles" : if category . lower ( ) in tag_keys : if i == 0 : first_border = "color1_top" else : first_border = "" nbr_notebooks = len ( dict_by_tag [ category . lower ( ) ] ) markdown_cell += "\n\t<tr>" "\n\t\t<td rowspan='" + str ( nbr_notebooks + 1 ) + "' class='center_cell open_cell_border_" + str ( NOTEBOOK_KEYS [ category ] ) + "'><span style='float:center'><img src='../../images/icons/" + category + ".png' class='icon' style='vertical-align:middle'></span> <span style='float:center' class='color" + str ( NOTEBOOK_KEYS [ category ] ) + "'>" + category + "</span></td>" "\n\t\t<td class='center_cell color" + str ( NOTEBOOK_KEYS [ category ] ) + "_cell " + first_border + "'><span style='float:center'>" + category + "</span></td>" "\n\t\t<td class='center_cell gradient_color" + str ( NOTEBOOK_KEYS [ category ] ) + "'></td>" "\n\t</tr>" notebook_list = dict_by_tag [ category . lower ( ) ] for j , notebook_file in enumerate ( notebook_list ) : if j == len ( notebook_list ) - 1 : last_border = "class='border_cell_bottom_white'" else : last_border = "" split_path = notebook_file . replace ( "\\" , "/" ) . split ( "/" ) notebook_name = split_path [ - 1 ] . split ( "&" ) [ 0 ] notebook_title = split_path [ - 1 ] . split ( "&" ) [ 1 ] markdown_cell += "\n\t<tr " + last_border + ">" "\n\t\t<td class='center_cell open_cell_light'> <a href='../" + category + "/" + notebook_name + "'>" + notebook_title + "</a> </td>" "\n\t\t<td class='center_cell'> <a href='../" + category + "/" + notebook_name + "'><div class='file_icon'></div></a> </td>" "\n\t</tr>" markdown_cell += "\n</table>" markdown_cell += DESCRIPTION_CATEGORY notebook_object [ "cells" ] . append ( nb . v4 . new_markdown_cell ( markdown_cell ) )
Internal function that is used for generation of the page "Notebooks by Category".

    ----------
    Parameters
    ----------
    notebook_object : notebook object
        Object of "notebook" class where the body will be created.

    dict_by_tag : dict
        Dictionary where each key is a tag and the respective value will be a list containing the
        Notebooks (title and filename) that include this tag.