Hi all,
I have got an interesting problem . I have got a sample Data below:
[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]1[/TD]
[TD]2[/TD]
[TD]4[/TD]
[TD]4[/TD]
[TD]1[/TD]
[TD]2[/TD]
[TD]2[/TD]
[TD]3[/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]13[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]5.5[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
I have got a target number in A2. I need to find how much of the range A1:I1 that number would cover. Each cell in the range is a day, and the value is sales per that day.
In the example, the coverage is 5.5 days (A3 cell) as I need A1:E1 and half of F1 to match the number.
I would have a few thousand calculations in the sheet, finding coverage for different products for stock levels in various points of time.
Currently I am using IFS function, that checks all of the scenarios (will stock cover 1 day -> what about 2 -> and 3 ->and 4 -> and so on...).
The current approach is working, but makes the entire calculation massive as I have more than 15 if conditions.
Multiply all that by a thousand or so of formula instances and we bordering unacceptable performance levels.
I was wondering if anyone has encountered something similar and has found a more elegant solution.
I have got an interesting problem . I have got a sample Data below:
[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]1[/TD]
[TD]2[/TD]
[TD]4[/TD]
[TD]4[/TD]
[TD]1[/TD]
[TD]2[/TD]
[TD]2[/TD]
[TD]3[/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]13[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]5.5[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
I have got a target number in A2. I need to find how much of the range A1:I1 that number would cover. Each cell in the range is a day, and the value is sales per that day.
In the example, the coverage is 5.5 days (A3 cell) as I need A1:E1 and half of F1 to match the number.
I would have a few thousand calculations in the sheet, finding coverage for different products for stock levels in various points of time.
Currently I am using IFS function, that checks all of the scenarios (will stock cover 1 day -> what about 2 -> and 3 ->and 4 -> and so on...).
The current approach is working, but makes the entire calculation massive as I have more than 15 if conditions.
Multiply all that by a thousand or so of formula instances and we bordering unacceptable performance levels.
I was wondering if anyone has encountered something similar and has found a more elegant solution.