Skip to content

Commit

Permalink
Add comments for removing empty rows and columns
Browse files Browse the repository at this point in the history
  • Loading branch information
ldavies99 committed Aug 20, 2024
1 parent 59a5324 commit 23f52c3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions gptables/examples/survey_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
parent_dir = Path(__file__).parent

labour_market_data = pd.read_csv(parent_dir / "survey_data.csv")
labour_market_data.dropna(axis=0, how="all", inplace=True)
labour_market_data.dropna(axis=1, how="all", inplace=True)
labour_market_data.dropna(axis=0, how="all", inplace=True) # Remove empty rows in the data
labour_market_data.dropna(axis=1, how="all", inplace=True) # Remove columns rows in the data
col_names = ["Time period and dataset code row",
"Number of people",
"Economically active",
Expand Down Expand Up @@ -99,8 +99,8 @@

## Notesheet
notes_table = pd.read_csv(parent_dir / "survey_data_notes.csv")
notes_table.dropna(axis=0, how="all", inplace=True)
notes_table.dropna(axis=1, how="all", inplace=True)
notes_table.dropna(axis=0, how="all", inplace=True) # Remove empty rows in the data
notes_table.dropna(axis=1, how="all", inplace=True) # Remove columns rows in the data
notes_table.columns = ['Note reference', 'Note text']

## Use write_workbook to win!
Expand Down

0 comments on commit 23f52c3

Please sign in to comment.