View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_7_] Bob Phillips[_7_] is offline
external usenet poster
 
Posts: 1,120
Default Translate these worksheet function to VB

a very simple way is

LogBCoef =Evaluate("INDEX(LINEST(YValues,LN(XValues)),1,2)" )


--
HTH

Bob Phillips

"GH" wrote in message
oups.com...
I have the following named formulas in my workbook and I would like to
calculate results in VB and display in a message box.

LogBCoef =INDEX(LINEST(YValues,LN(XValues)),1,2)
LogCCoef =INDEX(LINEST(YValues,LN(XValues)),1)
PolyBCoef =INDEX(LINEST(YValues,XValues^{1,2}),1,3)
PolyC1Coef =INDEX(LINEST(YValues,XValues^{1,2}),1,2)
PolyC2Coef =INDEX(LINEST(YValues,XValues^{1,2}),1)
PowerBCoef =INDEX(LINEST(LN(YValues),LN(XValues),,),1)
PowerCCoef =EXP(INDEX(LINEST(LN(YValues),LN(XValues),,),1,2))
ExpBCoef =INDEX(LINEST(LN(YValues),XValues),1)
ExpCCoef =EXP(INDEX(LINEST(LN(YValues),XValues),1,2))


YValues and XYalues are named ranges.
The syntax is giving me fits. Can anyone help?