{"id":28267590,"url":"https://github.com/dipto9999/excel_spreadsheet_organizer","last_synced_at":"2026-05-04T11:40:53.169Z","repository":{"id":163800112,"uuid":"398653199","full_name":"Dipto9999/Excel_Spreadsheet_Organizer","owner":"Dipto9999","description":"Using Python open-source libraries, organize and modify information from excel and xml files for better readability.","archived":false,"fork":false,"pushed_at":"2021-08-21T20:46:24.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-06-19T10:42:02.528Z","etag":null,"topics":["excel","jupyter-notebook","openpyxl","pandas","python","xml"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Dipto9999.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-08-21T20:46:21.000Z","updated_at":"2022-10-12T22:30:16.000Z","dependencies_parsed_at":null,"dependency_job_id":"3ef87acc-f11f-4243-b8de-21234bb2c20d","html_url":"https://github.com/Dipto9999/Excel_Spreadsheet_Organizer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Dipto9999/Excel_Spreadsheet_Organizer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dipto9999%2FExcel_Spreadsheet_Organizer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dipto9999%2FExcel_Spreadsheet_Organizer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dipto9999%2FExcel_Spreadsheet_Organizer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dipto9999%2FExcel_Spreadsheet_Organizer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dipto9999","download_url":"https://codeload.github.com/Dipto9999/Excel_Spreadsheet_Organizer/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dipto9999%2FExcel_Spreadsheet_Organizer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272733351,"owners_count":24984261,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-29T02:00:10.610Z","response_time":87,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["excel","jupyter-notebook","openpyxl","pandas","python","xml"],"created_at":"2025-05-20T15:11:12.246Z","updated_at":"2026-05-04T11:40:47.497Z","avatar_url":"https://github.com/Dipto9999.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Excel Spreadsheet Organizer\n\n## Contents\n* [Overview](#Overview)\n    * [Solution Details](#Solution-Details)\n\n## Overview\nThis was a short task completed for a confidential corporate organizer where information from an \u003ca href = \"test_excel_1.xlsx\"\u003e\u003cb\u003eExcel Spreadsheet\u003c/b\u003e\u003c/a\u003e was\nmodified and combined with information extracted from an \u003cb\u003e\u003ca href = \"test_xml.xml\"\u003eXML\u003c/a\u003e\u003c/b\u003e file to create a table in another \u003cb\u003e\u003ca href = \"test_excel_2.xlsx\"\u003eExcel Spreadsheet\u003c/a\u003e\u003c/b\u003e. This was done through the use of open-source libraries in \u003cb\u003ePython\u003c/b\u003e and run in \u003ca href= \"test_notebook.ipynb\"\u003e\u003cb\u003eJupyter Notebook\u003c/b\u003e\u003c/a\u003e. This allowed me to further explore the \u003cb\u003ePandas Library\u003c/b\u003e and become more familiar working with \u003cb\u003eDataFrames\u003c/b\u003e.\n\n\u003ci\u003eNote : All sensitive information has been modified and replaced.\u003c/i\u003e\n\n### Solution Details\nA few custom functions were built to shorten strings with a common prefixes, as shown here :\n\n```python\n# This function shortens an ID from the Excel file.\ndef shorten_id(original_column) :\n    length_to_cut = len('Delete Account ')\n    length_total = len(original_column)\n    truncated_column = original_column[length_to_cut: length_total]\n\n    return truncated_column\n```\n\n```python\n# This function shortens the role information from the XML file.\ndef shorten_role(original_column) :\n    length_to_cut = len('Role=')\n    length_total = len(original_column)\n    truncated_column = original_column[length_to_cut: length_total]\n\n    return truncated_column\n```\n\nThe XML file was iterated through using \u003cb\u003eElementTree Library\u003c/b\u003e built-in functions, as shown here :\n\n```python\n# Iterate through XML file to filter and organize relevant information.\nfor account in root.iter('account') :\n    id = account.get('id', default = None)\n\n    for i in range(id_series.size) :\n        # If ID is found in the ID series, execute code.\n        if (id == id_series[i]) :\n            # Add this unordered ID to the list.\n            xml_ids.append(id)\n\n            # Assign role column to have the role information.\n            for attribute in account.iter('attribute') :\n                if attribute.get('name') == 'Role' :\n                    attributeValueRef_id = str()\n\n                    for attributeValueRef in attribute.iter('attributeValueRef') :\n                        # Remove the 'Role=' using the custom function before acquiring the information.\n                        attributeValueRef_id += shorten_role(attributeValueRef.get('id')) + ' \\n'\n                    # Append each string to the list if the ID is found in the ID series.\n                    role_column.append(attributeValueRef_id)\n```\n\nThe ID and role columns were matched by iterating through the respective \u003cb\u003eDataFrame\u003c/b\u003e and \u003cb\u003eList\u003c/b\u003e.\n\n```python\n# Organize role column to match the ordered ID series.\nfor organized_index in range(id_series.size) :\n    # Add an empty string to end of list to account for IDs with blank roles.\n    organized_role_column.append('')\n    for unorganized_index in range(len(xml_ids)) :\n        if (id_series[organized_index] == xml_ids[unorganized_index]) :\n            # Replace empty string for IDs with roles in the XML file.\n            organized_role_column.insert(organized_index, (role_column[unorganized_index]))\n```\n\nThere is also a \u003ca href = \"test_script.py\"\u003e\u003cb\u003ePython Script\u003c/b\u003e\u003c/a\u003e written with additional comments to further understand the procedure of developing this organizer.\n\n\u003cp align = \"center\"\u003e\u003ci\u003eNote : This Exploration Took a Weekend to Complete, Spanning Approximately 10 Hours Altogether.\u003c/i\u003e\u003c/p\u003e","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdipto9999%2Fexcel_spreadsheet_organizer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdipto9999%2Fexcel_spreadsheet_organizer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdipto9999%2Fexcel_spreadsheet_organizer/lists"}