Dosnox
Board Regular
- Joined
- Apr 2, 2012
- Messages
- 52
HI All,
I had a look around and couldn't figure out how to do this. I'm working on some legacy spreadsheets and updating the formula's to be more dynamic rather than fixed to accommodate when new data is added.
I'm having a bit of trouble showing what my dummy data table looks looks like but it sort of looks like this
[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD][/TD]
[TD]No of Weekdays[/TD]
[TD]Total Days[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Week 1[/TD]
[TD]5[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Week 2[/TD]
[TD]5[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Week 1[/TD]
[TD]3[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD]Week 2[/TD]
[TD]5[/TD]
[TD]7[/TD]
[/TR]
</tbody>[/TABLE]
In another cell I've currently got the array formula below where my E1 has the value 'Week 1'
as part of the calculation the array is returned below
{0.714285714285714;0;0;0;0;0;0;0;0;0.428571428571429;0;0;0;0}
I'd like it to return the array below(exlcudes the zero's) instead as I want to multiply it by another array of size 2
{0.714285714285714;0.428571428571429;}
Hopefully this makes sense, let me know if it requires clarification and thanks for your help!
Thanks,
Shan
I had a look around and couldn't figure out how to do this. I'm working on some legacy spreadsheets and updating the formula's to be more dynamic rather than fixed to accommodate when new data is added.
I'm having a bit of trouble showing what my dummy data table looks looks like but it sort of looks like this
[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD][/TD]
[TD]No of Weekdays[/TD]
[TD]Total Days[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Week 1[/TD]
[TD]5[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Week 2[/TD]
[TD]5[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Week 1[/TD]
[TD]3[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD]Week 2[/TD]
[TD]5[/TD]
[TD]7[/TD]
[/TR]
</tbody>[/TABLE]
In another cell I've currently got the array formula below where my E1 has the value 'Week 1'
Code:
={SUMPRODUCT(IF($C$2:$C$6>0,($B$2:$B$6/C$2:$C$6)*($A$2:$A$6=E1),0))}
as part of the calculation the array is returned below
{0.714285714285714;0;0;0;0;0;0;0;0;0.428571428571429;0;0;0;0}
I'd like it to return the array below(exlcudes the zero's) instead as I want to multiply it by another array of size 2
{0.714285714285714;0.428571428571429;}
Hopefully this makes sense, let me know if it requires clarification and thanks for your help!
Thanks,
Shan