<html>
<head>
<base href="https://bugs.documentfoundation.org/">
</head>
<body><span class="vcard"><a class="email" href="mailto:erack@redhat.com" title="Eike Rathke <erack@redhat.com>"> <span class="fn">Eike Rathke</span></a>
</span> changed
<a class="bz_bug_link
bz_status_ASSIGNED "
title="ASSIGNED - OFFSET function in array context compatibility with Excel"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=58874">bug 58874</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Status</td>
<td>NEW
</td>
<td>ASSIGNED
</td>
</tr>
<tr>
<td style="text-align:right;">Assignee</td>
<td>libreoffice-bugs@lists.freedesktop.org
</td>
<td>erack@redhat.com
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_ASSIGNED "
title="ASSIGNED - OFFSET function in array context compatibility with Excel"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=58874#c12">Comment # 12</a>
on <a class="bz_bug_link
bz_status_ASSIGNED "
title="ASSIGNED - OFFSET function in array context compatibility with Excel"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=58874">bug 58874</a>
from <span class="vcard"><a class="email" href="mailto:erack@redhat.com" title="Eike Rathke <erack@redhat.com>"> <span class="fn">Eike Rathke</span></a>
</span></b>
<pre>So indeed, for OFFSET in array context Excel returns an array of references,
e.g. OFFSET(A1,ROW(1:3),0,2) returns
A2:A3
A3:A4
A4:A5
which then fed to SUBTOTAL calculates each independently and returns an array
of results.
With A1:A5={1;2;4;8;16} and =SUBTOTAL(9,OFFSET(A1,ROW(1:3),0,2)) the result is
{6;12;24}
Same for =SUM(OFFSET(A1,ROW(1:3),0,2)) in array context.
I assume the same works for all functions that can be specified as SUBTOTAL
first argument, at least it does for AVERAGE as well.
(Note: {1;2;3} should be the same as ROW(1:3) but Excel does not accept the
inline array.)</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>