RSX
RSX

Reputation: 374

FORECAST function row by row (google-sheets)

I can successfully use the Google Sheets FORECAST function like this:

FORECAST example 1

However, due the shape and size of my data, what I really want to do is use it like this:

enter image description here

However, this throws a divide by zero error. So, either I'm doing it wrong (likely) or the function doesn't like swapping its x's & y's?

Any ideas on how to achieve this would be much appreciated.

Upvotes: 1

Views: 349

Answers (1)

nabais
nabais

Reputation: 2037

I couldn't replicate the error as my google sheets the same values worked fine:

enter image description here

So, I have 2 options you can try:

  • you can wrap the arrays with the N() function: =forecast(F11,arrayformula(n(A12:E12)),arrayformula(n(A11:E11)))
  • make sure the values are well formatted: the values of the dates should be dates and the values of the numbers are numbers:

enter image description here

Let me know if any solution worked =)

Upvotes: 2

Related Questions