Thanks; I really appreciate all your efforts. But no, as far as I 
understand, the Poly type in Polynomial is not parametrized by a degree. I 
think there was a discussion lately, "How can Julia recognise the degree of 
a polynomial", that might be relevant.

You see, I am a hard-core numerical analyst and I try to bother with the 
type system only as much as is absolutely necessary for getting the speed 
out of Julia. Hope the Julia developers do not feel too much displease with 
this attitude. I do admire their work.


On Thursday, May 8, 2014 3:27:55 PM UTC+2, Andreas Noack Jensen wrote:
>
> Sorry for being too brief. My notation was not clear. The first argument 
> should be a type and not an instance. This is becoming the standard way of 
> fitting models deriving from StatsBase and Distributions. Hence, provided 
> that your polynomial type is parametrised by its degree, the definition 
> could be something like fit(::Type{Polynomial{3}), Formula, data) 
> or fit(::Type{Polynomial{3}), y::Vector, x::Vector).
>
>
> 2014-05-08 15:07 GMT+02:00 Hans W Borchers <hwbor...@gmail.com<javascript:>
> >:
>
>> Actually, I called it pfit(); is that name also given?
>> I don't understand your signature because a polynomial will not be 
>> provided, only data and a degree.
>>
>> How can I see a list of function names in Julia, JuliaBase, ... and 
>> packages on the METADATa list.
>> [As long as I really don't understand the namespace concept in Julia.]
>>
>>
>> On Thursday, May 8, 2014 2:41:59 PM UTC+2, Andreas Noack Jensen wrote:
>>
>>> I'd suggest fit(Polynomial, data) instead of polyfit(data). The generic 
>>> fit function is defined in StatsBase.
>>>
>>>  

Reply via email to