N
newbie
I just got a book called, Excel for Chemists. But it didnt tell me
something i want to know.
I wonder if someone out there can help me?
Here is the problem, say that i have put some data into a worksheet.
A1 cell = XValues and A2 cell = YValues.
If i have a Function that takes 2 arguments below how do i write code
to pass, XValues, Yvalues to the function Deming?
Example below:
Function Deming(XValues, Yvalues)
Dim MeanX(), MeanY()
'Get number of cells to use in calculation loop
Ncells = XValues.Count
ReDim MeanX(Ncells / 2), MeanY(Ncells / 2)
N = 0
put code here......do something...
'Define the return results as an array
Deming = Array(Slope, Intercept)
End Function
I would like to ask a related question as well. To run the programs
do name the subroutines and functions as macros? Then run the macros
by using the contextual menu and select macro/run/ macro name?
Thank you in advance,
Andrew
something i want to know.
I wonder if someone out there can help me?
Here is the problem, say that i have put some data into a worksheet.
A1 cell = XValues and A2 cell = YValues.
If i have a Function that takes 2 arguments below how do i write code
to pass, XValues, Yvalues to the function Deming?
Example below:
Function Deming(XValues, Yvalues)
Dim MeanX(), MeanY()
'Get number of cells to use in calculation loop
Ncells = XValues.Count
ReDim MeanX(Ncells / 2), MeanY(Ncells / 2)
N = 0
put code here......do something...
'Define the return results as an array
Deming = Array(Slope, Intercept)
End Function
I would like to ask a related question as well. To run the programs
do name the subroutines and functions as macros? Then run the macros
by using the contextual menu and select macro/run/ macro name?
Thank you in advance,
Andrew