# Help With Wrangling Dates in Python

**URL:** <https://discuss.python.org/t/help-with-wrangling-dates-in-python/22253>\
**Category:** Python Help\
**Created:** [December 28, 2022, 3:43pm UTC](https://discuss.python.org/t/help-with-wrangling-dates-in-python/22253 "2022-12-28T15:43:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![AbeCruz](https://avatars.discourse-cdn.com/v4/letter/a/9de0a6/32.png) [@AbeCruz](https://discuss.python.org/u/AbeCruz)\
**Post date:** [December 28, 2022, 3:43pm UTC](https://discuss.python.org/t/help-with-wrangling-dates-in-python/22253/1 "2022-12-28T15:43:44Z")

</div>

Hi There.  
Please see the attatchment “Py Question” to view my dataset.  
 ![Py Question](https://us1.discourse-cdn.com/flex002/uploads/python1/original/2X/b/b434ee87034413e9d863319097cf27a20d25996c.jpeg)

Question 1  
In Column C (Rating on the first day of the week  
I want to write a code that only copies, Ratings for the first day of Week and the repeat the same process.

Question 2  
In Column D (Rating on the Last day of the week  
I want to write a code that only copies, Ratings for the lastday of Week and the repeat the same process.

How would I do it on my Jupyter notebook?

---

<div class="post-metadata">

**Author:** ![Rosuav](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/rosuav/32/3429_2.png) [@Rosuav](https://discuss.python.org/u/Rosuav)\
**Post date:** [December 28, 2022, 3:44pm UTC](https://discuss.python.org/t/help-with-wrangling-dates-in-python/22253/2 "2022-12-28T15:44:42Z")

</div>

> **[datetime — Basic date and time types](https://docs.python.org/3/library/datetime.html)**
>
> Source code: Lib/datetime.py The datetime module supplies classes for manipulating dates and times. While date and time arithmetic is supported, the focus of the implementation is on efficient attr...

---

<div class="post-metadata">

**Author:** ![pylang](https://avatars.discourse-cdn.com/v4/letter/p/7feea3/32.png) [@pylang](https://discuss.python.org/u/pylang)\
**Post date:** [December 29, 2022, 12:17am UTC](https://discuss.python.org/t/help-with-wrangling-dates-in-python/22253/3 "2022-12-29T00:17:10Z")

</div>

Assuming it’s just date wrangling you’re doing, you can try external, “human-friendly” options as well:

- [maya](https://github.com/timofurrer/maya)
- [pendulum](https://pendulum.eustace.io/docs/)
- [delorean](https://delorean.readthedocs.io/en/latest/)
- [arrow](https://arrow.readthedocs.io/en/latest/)

To wrangle tabular data, I’d consider trying the external `pandas` library or the internal `csv` module.
