[Solved] Trying to Simplify a Formula

Discuss the spreadsheet application
Post Reply
daveg7
Posts: 48
Joined: Wed Sep 27, 2017 5:01 pm

[Solved] Trying to Simplify a Formula

Post by daveg7 »

Please upload the spreadsheet.

The formulas in column F (under "Results") work perfectly, except that I hope there's a simpler formula that would do the job.

Any ideas (I wonder if there's a way to adapt something like one of the lookup functions)?
Attachments
Formula Question.ods
(17.79 KiB) Downloaded 105 times
Last edited by daveg7 on Mon Oct 23, 2017 4:56 am, edited 3 times in total.
OpenOffice 4.1.3 with Windows 10
OpenOffice 4.1.3 with MacOS 10.4
Excel 2003 and 2010 with Windows 10 Pro and 32 GB Ram
Excel with MacOS 10.4
User avatar
Zizi64
Volunteer
Posts: 11361
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: Trying to Simplify a Formula

Post by Zizi64 »

Formula Question Zizi64.ods
(16.94 KiB) Downloaded 113 times
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
daveg7
Posts: 48
Joined: Wed Sep 27, 2017 5:01 pm

Re: Trying to Simplify a Formula

Post by daveg7 »

Beautiful, clear formula.

THANKS!
---

However, I added many columns to the original sheet, and again made your new formula long, as follows:

=IF(NOT(ISNA(MATCH(Q527;O$5:O$5001;0)))+NOT(ISNA(MATCH(S527;O$5:O$5001;0)))+NOT(ISNA(MATCH(U527;O$5:O$5001;0)))+NOT(ISNA(MATCH(W527;O$5:O$5001;0)))+NOT(ISNA(MATCH(X527;O$5:O$5001;0)))+NOT(ISNA(MATCH(Y527;O$5:O$5001;0)))+NOT(ISNA(MATCH(Z527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AA527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AB527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AC527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AD527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AE527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AF527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AG527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AH527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AI527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AJ527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AK527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AL527;O$5:O$5001;0)))+NOT(ISNA(MATCH(AM527;O$5:O$5001;0)));"Y";"N")

It now refers to cells in cols Q, S, U, and W:AM. I could, ideally, combine all the columns into one range Q:AJ and then hope someone's imagination (and knowledge of the syntax) is equal to simplifying the formula yet again.
Last edited by daveg7 on Sun Oct 22, 2017 7:58 am, edited 1 time in total.
OpenOffice 4.1.3 with Windows 10
OpenOffice 4.1.3 with MacOS 10.4
Excel 2003 and 2010 with Windows 10 Pro and 32 GB Ram
Excel with MacOS 10.4
User avatar
acknak
Moderator
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: Trying to Simplify a Formula

Post by acknak »

Another approach: in F4: =SUMPRODUCT($G4:$I4=E$4:E$13)

The formula gives the number of matches. To display this as Y or N, change the cell format to: "Y";"N";"N"

Drag-fill down to the cells below.
AOO4/LO5 • Linux • Fedora 23
daveg7
Posts: 48
Joined: Wed Sep 27, 2017 5:01 pm

Re: Trying to Simplify a Formula

Post by daveg7 »

Wow! This works, and it's very simple.

Thanks!

Also, I tried separating the columns into two ranges and the following worked just fine:

=SUMPRODUCT($G4:$H4=E$4:E$13)+SUMPRODUCT($K4=E$4:E$13)
OpenOffice 4.1.3 with Windows 10
OpenOffice 4.1.3 with MacOS 10.4
Excel 2003 and 2010 with Windows 10 Pro and 32 GB Ram
Excel with MacOS 10.4
Post Reply