write some python code, very easy 5 minute job
Orçamento £10-20 GBP
I have a very small amount of python code that i need written. It should probably only take 5 minutes to write but I'm new to python so it would take me a lot longer. Here are some details.
I have a pandas dataframe, something like this one shown below:
league match_date team
Argentine Division 1 12/25/2022 272
Argentine Division 1 12/25/2022 272
Argentine Division 1 12/25/2022 272
Argentine Division 1 4/7/2022 272
Argentine Division 1 6/25/2022 272
Argentine Division 1 6/21/2022 272
Argentine Division 1 12/25/2022 283
Argentine Division 1 12/25/2022 283
Argentine Division 1 12/25/2022 283
Argentine Division 1 3/7/2022 283
Argentine Division 1 6/25/2022 283
Argentine Division 1 3/7/2022 299
Argentine Division 1 6/26/2022 299
Argentine Division 1 6/20/2022 299
I need to edit the dates in the match_date column using the following criteria:
if the match_date = 12/25/2022 then leave the match_date unchanged.
if the match_date != 12/25/2022 then subtract 7 days from the match_date above.
So the first date below the cell match_date = 12/25/2022 would become match_date = 12/18/2022.
Continue this for the remaining rows. So below the cell match_date = 12/18/2022 would be match_date = 12/11/2022 and below that would be match_date = 12/04/2022 etc.
However when the value in the last column 'team' changes, for instance from 272 to 283 or from 283 to 299, I want the process to start again subtracting 7 days from 12/25/2022 and not the cell above.
The dates should update from the dataframe on the left to the dataframe on the right:
league match_date team league match_date team
Argentine Division 1 12/25/2022 272 Argentine Division 1 12/25/2022 272
Argentine Division 1 12/25/2022 272 Argentine Division 1 12/25/2022 272
Argentine Division 1 12/25/2022 272 Argentine Division 1 12/25/2022 272
Argentine Division 1 4/7/2022 272 Argentine Division 1 12/18/2022 272
Argentine Division 1 6/25/2022 272 Argentine Division 1 12/11/2022 272
Argentine Division 1 6/21/2022 272 Argentine Division 1 12/4/2022 272
Argentine Division 1 12/25/2022 283 Argentine Division 1 12/25/2022 283
Argentine Division 1 12/25/2022 283 Argentine Division 1 12/25/2022 283
Argentine Division 1 12/25/2022 283 Argentine Division 1 12/25/2022 283
Argentine Division 1 3/7/2022 283 Argentine Division 1 12/18/2022 283
Argentine Division 1 6/25/2022 283 Argentine Division 1 12/11/2022 283
Argentine Division 1 3/7/2022 299 Argentine Division 1 12/18/2022 299
Argentine Division 1 6/26/2022 299 Argentine Division 1 12/11/2022 299
Argentine Division 1 6/20/2022 299 Argentine Division 1 12/4/2022 299
Concedido a:
25 freelancers estão ofertando em média £16 nesse trabalho
Hi, I would like to help you with your Python pandas project. You can rely on me. I am an experienced developer and matematician. Looking forward to hear from you. Best regards, Oleg
Hello? How are you? Thanks for posting this job. I am a Senior Python developer with 7+ years. I have been doing this kind of python projects many times. Please let me know. Best Regards
Hi there, I can edit your pandas dataframe as you wanted. ping me to get your work done. Thank you .
Hi, I'm a Python Expert. I can manipulate the dates in the dataframe based on the the given condition. do contact me. Thank You
Greetings, I have gone through your project description. I find myself as a perfect fit for this job. I am working as a Python Developer from last 2 year. Some of my expertise is in the fields: 1. Web Scraping/Web Au Mais
Hi, I hope you are well I read your project description and I found I can help you well. I have a lot of experiences in python, and R Programming. I read your description for project carefully. I will very happy if yo Mais
Hi There, I Hope you are Doing Great !!! I have read your project and we have developed many python projects. I have 8+ years of experience in many engineering projects. I am a full stack developer experienced & skille Mais
Hi, I've read your description carefully. I have full experience with python I've also worked on several similar projects. So I can complete your project with high quality on time. Looking forward to hear more about th Mais
Hello there, Could you please send me your data? It can be done with Pandas apply and loc methods and other ordinary methods. Contact me over chat to talk more about the details. I have +4 years of experience working Mais
Hi I have huge experience in Data analytics , machine learning using Python scripting using Pandas, Numpy
Hello, Currently intern at the Friedrich Miescher Institute for Biomedical Research, I daily code in Python, R for our data analysis, We can tchat about it first, Cheers, Youn
Hello I am naresh kumar experienced python developer. I have made so many projects using different libraries of python. I have worked alot using numpy and pandas so I can give you the best services in a very short of Mais
write some python code, very easy 5 minute job Hello Patrick M., Hope you are doing great. I have read your project details. I have a great experience in Python. I am ready to start your project right now and I w Mais
Hey! I have vast experience in Python, NumPy and Pandas, and I am confident that I can produce quality content for you that will be of interest to your readers. I am available for a full-time writing position, and I a Mais