LINEST containing selection

B

Bob_Irving

Version: 2004 Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel I'm trying to do a regression for one set of of data out of many in a table, selecting on the basis of a cell in another, using a formula thusly:

=LINEST(IF(SWHP_Refs=B5,SWCOP,),IF(SWHP_Refs=B5,SWLift,))

However, the LINEST function is, I think, including zeros in the regression for each row in the table not selected by the IFs, giving me erroneous answers, because it's dividing by a count of all the items in the table. If I remove the comma for the false value in the IF, it returns FALSE and LINEST does not like that.

Any ideas?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top