How do a merge two arrays in Infinity datasource with UQL

I am using the Infinity Datasource to connect to Dynatrace (API). The Dynatrace plugin doesn’t give me all i need. But when getting time series data the values and timestamps are two separate arrays. I am struggling how to merge them together. I am usin UQL and if i use mv_expand on both then it matches each value from each array to the other. I put a small sample below. any help is appreciated.

{
“totalCount”: 10,
“nextPageKey”: null,
“resolution”: “1m”,
“result”: [
{
“metricId”: “builtin:host.cpu.usage:names:filter(in("dt.entity.host",entitySelector("type(~"HOST~"),tag(~"appcode:aaa~")"))):splitBy("dt.entity.host.name"):sort(dimension("dt.entity.host.name",ascending)):avg”,
“dataPointCountRatio”: 6.0E-5,
“dimensionCountRatio”: 1.0E-4,
“data”: [

            {
                "dimensions": [
                    "hostxxx@yyy.com"
                ],
                "dimensionMap": {
                    "dt.entity.host.name": "hostxxx@yyy.com"
                },
                "timestamps": [
                    1701090120000,
                    1701090180000,
                    1701090240000,
                    1701090300000,
                    1701090360000

                ],
                "values": [
                    90.19648106892903,
                    90.06653912862141,
                    91.63350741068523,
                    91.0315596262614,
                    92.09268697102864
                ]
            }
        ]
    }
]

}

Look at the $zip function in jsonata

Thanks. All examples i see of using JSONata are for filtering. do you have a good reference for making this call from infinity?

search in this forum for tons of examples of using jsonata with infinity plugin.

Something like this

I appreciate your reply. I always try and search before I post. I only see six items come up when I seach for jsonata examples. i am not asking you to do the heavy lifting, but if you can show me the rest of the map statement i think i can figure it out. All examples i see of the $map only return one result. i am using the jsonata execiser to test it. thank you

Here is one of many examples. Also search for https://try.jsonata.org/
in this forum.