@jonsonbero One word of advice: User Defined Functions (UDF) are much slower than formulas written directly in cells using built-in Excel functions. I would advise to stay away from VBA for this and rather use formulas. If your formulas become to complicated, perhaps splitting the calculation across multiple is an option?