As a followup, I realized that GLM put the interaction variable at the end
of the estimates in the coeftable output. Is there any way I can preserve
the order such that the variables are shown in order (e.g., LStat, Age, and
LStat and Age intertion in that order).
On Wednesday, May 14, 2014 at 12:04:00 PM UTC-4, Douglas Bates wrote:
>
> I think the problem is with third and higher order interactions.
>
> On Tuesday, May 13, 2014 8:44:38 PM UTC-5, Taylor Maxwell wrote:
>>
>> It works fine for me although I am using the latest master version of GLM
>> so I need to use fit(LmMod, formula,df)
>>
>> using RDatasets, GLM
>> boston = dataset("MASS", "Boston")
>>
>> julia> cc=fit(LmMod,MedV ~ LStat+Age+LStat&Age, boston)
>> DataFrameRegressionModel{LmMod{DensePredQR{Float64}},Float64}:
>>
>> Coefficients:
>> Estimate Std.Error t value Pr(>|t|)
>> (Intercept) 36.0885 1.46984 24.5528 < eps()
>> LStat -1.39212 0.167456 -8.31335 8.8e-16
>> Age -0.00072086 0.0198792 -0.0362621 0.9711
>> LStat & LStat 0.00415595 0.0018518 2.24428 0.0252
>>
>>
>> On Tuesday, May 6, 2014 10:13:36 AM UTC-6, Johan Sigfrids wrote:
>>>
>>> How do you specify interactions and non-linear transforms using the
>>> fomula for GLM? Something like y~x1*x2 + x2^2
>>>
>>
--
You received this message because you are subscribed to the Google Groups
"julia-stats" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.