Hey @Christiaan_Huizer,
Strictly speaking, it’s not “multiplication” (because that would make an N x N matrix) but more of “masking”.
The logic here is to multiply Nth element of the first list by the Nth element of the second list. Which means you still have to iterate (i.e. perform the same operation once per list item) but instead of iterating on items themselves you should iterate on indices 1, 2, 3 ... List.Count()
so that you can use the same index on both list to extract corresponding values:
Sequence(1, thisRow.transformed.Count()).FormulaMap(
thisRow.transformed.Nth(CurrentValue) * thisRow.[days per response].Nth(CurrentValue)
)
Here I’m making another list that’s a sequence of numbers from 1 to transformed.Count()
and then I’m using items in this list (numbers from 1 to last) to get .Nth()
element of each list and multiply them to produce Nth element of a resulting list.
I implemented this in your doc. Btw, no need to use ListCombine()
there — simply use List()
to create a list of elements that you enumerate as function parameters. Also no need to ListCombine()
on a column — you can simply reference that column (see Input 2 / Days per response column)