def create_body_component_l(data: GTData) -> str:
    """
    Create the body component for LaTeX output.

    This function generates the LaTeX code for the body component of a table which involves the
    data cells, the row groups, and the stub.

    Parameters
    ----------
    data : GTData
        The GTData object that contains all the information about the table.

    Returns
    -------
    str
        The LaTeX code for the body component of the table.
    """

    _str_orig_data = cast_frame_to_string(data._tbl_data)
    tbl_data = replace_null_frame(data._body.body, _str_orig_data)

    # Get the default column vars
    column_vars = data._boxhead._get_default_columns()

    body_rows = []

    ordered_index: list[tuple[int, GroupRowInfo | None]] = data._stub.group_indices_map()

    for i, _ in ordered_index:
        body_cells: list[str] = []

        # Create a body row
        for colinfo in column_vars:
            cell_content = _get_cell(tbl_data, i, colinfo.var)
            cell_str: str = str(cell_content)

            body_cells.append(cell_str)

        # When joining the body cells together, we need to ensure that each item is separated by
        # an ampersand and that the row is terminated with a double backslash
        body_cells = " & ".join(body_cells) + " \\\\"

        body_rows.append("".join(body_cells))

    # When joining all the body rows together, we need to ensure that each row is separated by
    # newline except for the last

    all_body_rows = "\n".join(body_rows)

    return all_body_rows

    Create the body component for LaTeX output.

    This function generates the LaTeX code for the body component of a table which involves the
    data cells, the row groups, and the stub.

    Parameters
    ----------
    data : GTData
        The GTData object that contains all the information about the table.

    Returns
    -------
    str
        The LaTeX code for the body component of the table.
    
great_tables/_utils_render_latex.py