Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Darius Blaszijk
 
Posts: n/a
Default performing least squares

Hello,

I have the following data;

y x1 x2
12 1 10
23 2 20
34 3 30
45 4 40
56 5 50


And I would like to fit the following formula to this dataset; "x1^2 + x2 *
x1 = y"

Can anybody give me a pointer on how to do this, preferebly without having
to linearize the dataset first? The "algorithm" proposed should however be
able to fit any formula / model to the dataset, eg be general about this.

Kind regards, Darius Blaszijk


  #2   Report Post  
Jay Somerset
 
Posts: n/a
Default

On Thu, 17 Mar 2005 00:25:44 +0100, "Darius Blaszijk"
wrote:

Hello,

I have the following data;

y x1 x2
12 1 10
23 2 20
34 3 30
45 4 40
56 5 50


And I would like to fit the following formula to this dataset; "x1^2 + x2 *
x1 = y"

Can anybody give me a pointer on how to do this, preferebly without having
to linearize the dataset first? The "algorithm" proposed should however be
able to fit any formula / model to the dataset, eg be general about this.

Kind regards, Darius Blaszijk


You seem to be missing something. You can't fit the formula as you wrote it.

What coefficients are you trying to determine? Do you really mean you are
trying to find "a" and "b" that best fit the equation y = a*x1^2 b*x1*x2,
or y= a*x1*(x1 + b*x2) or y= x1*(a*x1+b*x2), or something else?

--
Jay.
(remove dashes for legal email address)
  #3   Report Post  
Darius Blaszijk
 
Posts: n/a
Default

Jay,

What I meant was the following; y = a*x1^2 b*x1*x2. But in fact it does not
matter as I need a general method.

Kind regards, Darius Blaszijk




"Jay Somerset" schreef in bericht
...
On Thu, 17 Mar 2005 00:25:44 +0100, "Darius Blaszijk"
wrote:

Hello,

I have the following data;

y x1 x2
12 1 10
23 2 20
34 3 30
45 4 40
56 5 50


And I would like to fit the following formula to this dataset; "x1^2 +

x2 *
x1 = y"

Can anybody give me a pointer on how to do this, preferebly without

having
to linearize the dataset first? The "algorithm" proposed should however

be
able to fit any formula / model to the dataset, eg be general about

this.

Kind regards, Darius Blaszijk


You seem to be missing something. You can't fit the formula as you wrote

it.

What coefficients are you trying to determine? Do you really mean you

are
trying to find "a" and "b" that best fit the equation y = a*x1^2 b*x1*x2,
or y= a*x1*(x1 + b*x2) or y= x1*(a*x1+b*x2), or something else?

--
Jay.
(remove dashes for legal email address)



  #4   Report Post  
Jerry W. Lewis
 
Posts: n/a
Default

x2 is a multiple of x1 so neither y = x1 + x2 nor y = x1^2 + x2*x1 have
uniquely determined coefficients.

If x2 were not a multiple of x1, then
LINEST(A2:A6,B2:B6*B2:C6)
would do the trick, assuming that column labels are in A1:C1 with data
in A2:C6.

Jerry

Darius Blaszijk wrote:

Hello,

I have the following data;

y x1 x2
12 1 10
23 2 20
34 3 30
45 4 40
56 5 50


And I would like to fit the following formula to this dataset; "x1^2 + x2 *
x1 = y"

Can anybody give me a pointer on how to do this, preferebly without having
to linearize the dataset first? The "algorithm" proposed should however be
able to fit any formula / model to the dataset, eg be general about this.

Kind regards, Darius Blaszijk


  #5   Report Post  
Jay Somerset
 
Posts: n/a
Default

On Thu, 17 Mar 2005 09:48:39 +0100, "Darius Blaszijk"
wrote:

Jay,

What I meant was the following; y = a*x1^2 b*x1*x2. But in fact it does not
matter as I need a general method.


It certainly does matter. But if you have already decided that you don't
need a definitive expression with coefficients, then no amount of advice is
going to help you. Sad to say, it seems as though you do not understand
least squares fits.


Kind regards, Darius Blaszijk




"Jay Somerset" schreef in bericht
...
On Thu, 17 Mar 2005 00:25:44 +0100, "Darius Blaszijk"
wrote:

Hello,

I have the following data;

y x1 x2
12 1 10
23 2 20
34 3 30
45 4 40
56 5 50


And I would like to fit the following formula to this dataset; "x1^2 +

x2 *
x1 = y"

Can anybody give me a pointer on how to do this, preferebly without

having
to linearize the dataset first? The "algorithm" proposed should however

be
able to fit any formula / model to the dataset, eg be general about

this.

Kind regards, Darius Blaszijk


You seem to be missing something. You can't fit the formula as you wrote

it.

What coefficients are you trying to determine? Do you really mean you

are
trying to find "a" and "b" that best fit the equation y = a*x1^2 b*x1*x2,
or y= a*x1*(x1 + b*x2) or y= x1*(a*x1+b*x2), or something else?

--
Jay.
(remove dashes for legal email address)



--
Jay.
(remove dashes for legal email address)


  #6   Report Post  
Tim Williams
 
Posts: n/a
Default

Darius,

If you want a "general" method then why not use solver? I've used this
in the past when fitting a dataset (assuming this is experimental
data) to one or more models. Works fine.

Tim


"Jay Somerset" wrote in message
...
On Thu, 17 Mar 2005 09:48:39 +0100, "Darius Blaszijk"
wrote:

Jay,

What I meant was the following; y = a*x1^2 b*x1*x2. But in fact it
does not
matter as I need a general method.


It certainly does matter. But if you have already decided that you
don't
need a definitive expression with coefficients, then no amount of
advice is
going to help you. Sad to say, it seems as though you do not
understand
least squares fits.


Kind regards, Darius Blaszijk




"Jay Somerset" schreef in bericht
...
On Thu, 17 Mar 2005 00:25:44 +0100, "Darius Blaszijk"
wrote:

Hello,

I have the following data;

y x1 x2
12 1 10
23 2 20
34 3 30
45 4 40
56 5 50


And I would like to fit the following formula to this dataset;
"x1^2 +

x2 *
x1 = y"

Can anybody give me a pointer on how to do this, preferebly
without

having
to linearize the dataset first? The "algorithm" proposed should
however

be
able to fit any formula / model to the dataset, eg be general
about

this.

Kind regards, Darius Blaszijk


You seem to be missing something. You can't fit the formula as
you wrote

it.

What coefficients are you trying to determine? Do you really
mean you

are
trying to find "a" and "b" that best fit the equation y = a*x1^2
b*x1*x2,
or y= a*x1*(x1 + b*x2) or y= x1*(a*x1+b*x2), or something else?

--
Jay.
(remove dashes for legal email address)



--
Jay.
(remove dashes for legal email address)



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macros not performing correctly fabulousk Excel Discussion (Misc queries) 4 March 7th 05 04:25 PM
removing squares and lines in squares that really should be paragr finnadat Excel Discussion (Misc queries) 5 February 10th 05 11:12 PM
Least Squares Analysis TNMAN Excel Worksheet Functions 2 February 8th 05 03:09 PM
How do I find template with tiny squares on the entire page kathiejo53 New Users to Excel 1 January 3rd 05 05:54 PM


All times are GMT +1. The time now is 02:49 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"