Date: prev next · Thread: first prev next last
2015 Archives by date, by thread · List index


For anyone who might have taken an interest in this discussion, I omitted a right parenthesis when 
I first posted this formula. It is now correct.

-- 
Jim

-----Original Message-----
From: James E Lang <jim+lou@lang.hm>
To: users@global.libreoffice.org, pete nikolic <pg.nikolic1@gmail.com>
Sent: Sat, 25 Apr 2015 11:47
Subject: Re: [libreoffice-users] selecting cells in calc sheet

The main thing I'm not understanding is whether the formula is to be one fixed place or if after 3 
data points it is in cell X but after 4 data points it is in cell Y. The solution I gave you 
applies to the latter case.

For the former case I would use a more complex formula like this using your latest specification.

=IF(COUNT(A1:A50)>2,AVERAGE(OFFSET(A1,0,COUNT(A1:A50)-3,1,3))-30,"")

That says, if there are more than two values then define a horizontal range composed of the last 
three filled cells, average that range, and subtract 30. This works as long as they are no empty or 
text cells before the values of interest in A1:A50. This process gets a little bit (to say the 
least) more hairy if there are intervening cells.

-- 
Jim

-- 
To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.