I have a set of data in the following format:
{
"Dates": ["January", "January", "March", "March", "March", "November", "November"],
"Values": [45.6, 0.5, 59.3, 46.56, 2.21, 48.59, 5.5]
}
My goal is to combine the values in "Values" (averaging) by month
The output I am aiming for:
{
"Dates":["January", "March", "November"],
"Values":[23.05, 36.02, 27]
}
I have come across various discussions on this topic, such as the one here. However, I am unsure how to implement it for an object with arrays. Any suggestions would be greatly appreciated. Thank you