Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1995
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1995

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Finding Regression Coefficient

  • To: mathgroup at christensen.cybernetics.net
  • Subject: [mg1157] Re: Finding Regression Coefficient
  • From: william.oliver at colorado.edu (Bill Oliver)
  • Date: Sat, 20 May 1995 01:23:21 -0400
  • Organization: University of Colorado

In article <3pc25e$o0m at news0.cybernetics.net>
tesch at titan.oit.umass.edu (Ralf Tesch) writes:

> Hi there,
> 
> being one of the many people having questions about NonlinearFit[], mine 
> is about finding the regression coefficient r^2 of the solution given by 
> Mma. 
> There is no hint in the Standard Packages Manual (at least I didn't find 
> any...)
> Is there a way implemented in Mma or is that coefficient to be calculated 
> seperately - how???
> Thanks for help
> 
> Ralf

The following should work for you, although you may need to manipulate
your data into the correct matrix form.
 
In[4]:=
<<Statistics`LinearRegression`
In[12]:=
data = Table[{Random[],Random[]},{100}];
In[13]:=
Regress[data,{1,x},x,OutputList->RSquared,OutputControl->NoPrint]
Out[13]=
RSquared -> 0.0712578

-Bill-



  • Prev by Date: Re: Piecewise function generator
  • Next by Date: "Topographical" Coloring?
  • Previous by thread: Finding Regression Coefficient
  • Next by thread: Re: Finding Regression Coefficient