-
캐글 data_cleaning/03-parsing-dates<Kaggle-Course> 2023. 3. 16. 18:24728x90
date_format = '%m/%d/%Y' earthquakes.loc[indices,'Date'] = pd.to_datetime(earthquakes.loc[indices,'Date']) \ .dt.strftime(date_format) earthquakes['date_parsed'] = pd.to_datetime(earthquakes['Date'])
day_of_month_earthquakes = earthquakes['date_parsed'].dt.day
date_lengths = earthquakes.Date.str.len() date_lengths.value_counts()
728x90'<Kaggle-Course>' 카테고리의 다른 글
캐글 data_cleaning/05-inconsistent-data-entry (0) 2023.03.16 캐글 data_cleaning/04-character-encoding (0) 2023.03.16 캐글 data_cleaning/02-scaling-and-normalization (0) 2023.03.16 캐글 data_cleaning/01-handling-missing-values (0) 2023.03.16 캐글 advanced_sql/04-writing-efficient-queries (0) 2023.03.15