Skip to content

Commit

Permalink
USCensusPEP_PopulationEstimatebyRace: Changes committed for duplicate…
Browse files Browse the repository at this point in the history
…s values (#1121)

* Auxilio Brazil Test Data and Readme file added

* reverted the changes

* SCHEDULES=cripts/us_census/pep/population_estimate_by_race:USCensusPEP_PopulationEstimatebyRace

* Lint errror fixed

* Added coments
  • Loading branch information
shamimansari1988 authored Nov 22, 2024
1 parent 0fccad7 commit 95d1c33
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1059,6 +1059,9 @@ def process(self):
(os.path.join(self.cleaned_csv_file_path,
"USA_Population_Count_by_Race_before_2000.csv"))
generator_df = generator_df[generator_df['geo_ID'].str.len() > 1]
#Duplicate geo_ID instances were detected within the 1970-1979 data subset. To ensure data integrity, the older entries were eliminated, leaving only the most recent updates.
generator_df = generator_df.drop_duplicates(
subset=['geo_ID', 'Year'], keep='last')
generator_df.to_csv(os.path.join(
self.cleaned_csv_file_path,
"USA_Population_Count_by_Race_before_2000.csv"),
Expand Down

0 comments on commit 95d1c33

Please sign in to comment.