Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2011

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

Search the Archive

Re: 2 obvious

  • To: mathgroup at smc.vnet.net
  • Subject: [mg115407] Re: 2 obvious
  • From: Francisco Gutierrez <fgutiers2002 at yahoo.com>
  • Date: Mon, 10 Jan 2011 02:38:36 -0500 (EST)

Many thanks to Darren and others who provided very useful answers to my query.
And happy 2011
Fg

--- On Tue, 1/4/11, Darren Glosemeyer <darreng at wolfram.com> wrote:

> From: Darren Glosemeyer <darreng at wolfram.com>
> Subject: [mg115231] Re: 2 obvious
> To: mathgroup at smc.vnet.net
> Date: Tuesday, January 4, 2011, 6:50 PM
> On 12/23/2010 2:55 AM, Francisco
> Gutierrez wrote:
> > Dear Group:
> > Ok, here comes a really silly question. After v. 7,
> the statistical capacities of Mathematica have been
> substantially boosted. However, I haven't been able to
> interpret the simple command LogitModelFit. THe problem is
> that the documentation only offers examples with two
> independent variables. I have not managed to find how can n
> more independent variables can be inserted so that the
> command works. Can somebody send me a simple and clear
> example?
> >
> > Let this be a pretext to thank all the incredibly
> useful help the members of this list have generously
> provided to me and others. Happy holidays,
> > Fg
> >
> >
> >
> >
>
> Hi Francisco,
>
> The data argument is like for other fitting functions. The
> independent
> (predictor) variables are the first n-1 elements in each
> data point and
> the last element in the data point is a dependent
> (response) variable.
>
> Here is a list of 5 data points each having two predictors
> and one response.
>
> In[1]:== data == {{10, 4, 0.26}, {8, 3, 0.04}, {2, 0, 0.17},
> {4, 8, 0.09},
> {9, 4, 0.83}};
>
> This treats the predictors as x and y in the fitting
>
> In[2]:== lm == LogitModelFit[data, {x, y}, {x, y}];
>
>
> and here we get the fitted function and a table of
> parameter information
> for the fitting.
>
> In[3]:== lm[{"BestFit", "ParameterTable"}]
>
>                
>             1
> Out[3]== {-------------------------------------,
>            
>    2.384 - 0.236963 x + 0.0664776 y
>           1 + E
>
>  >        Estimate 
>    Standard
> Error   z\[Hyphen]Statistic   
> P\[Hyphen]Value}
>
>       1   -2.384   
>    3.41536         
> -0.698022         
>    0.485163
>
>       x   0.236963 
>    0.388785     
>    0.609496         
>     0.542196
>
>      
> y   -0.0664776   0.529535 
>        -0.125539   
>          0.900097
>
>
>
> I hope this helps.
>
> Darren Glosemeyer
> Wolfram Research
>
>


     


  • Prev by Date: Re: How do I do very big integer computing by
  • Next by Date: Re: how to remove $RecursionLimit::reclim: and $IterationLimit::itlim:
  • Previous by thread: Re: 2 obvious
  • Next by thread: FillingStyle -> Striped ?