1
$\begingroup$

I have a set of json files that contains a list of weather parameters for every hour in a day for a complete month. The name of the Json files are in this format " 2016-1" where 2016 denotes the year and 1 denotes the month January. Now considering that the given data in the json file is in order, how can I add a new column to the dataframe that automatically fetches the month and the year from the file name and repeats the date 24 times until the month gets over. The date format should look like this > DD-MM-YYYY

Thanks in advance :)

$\endgroup$

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.