help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: non-linear fitting with bounds


From: Olaf Till
Subject: Re: non-linear fitting with bounds
Date: Mon, 15 Mar 2010 08:45:36 +0100
User-agent: Mutt/1.5.18 (2008-05-17)

On Mon, Mar 15, 2010 at 01:23:50AM +0100, Stefan Neumann wrote:
> not working:
> > # ------------------------------------ #
> > # function with 2 parameters
> > options.bounds=[1,2;1,2]
> > [f,p,kvg,iter,corp,covp,covr,stdresid,Z,r2]=leasqr(x,y,pin,F,options);
> > # ------------------------------------ #
> >
> >
> Found it:
> 
> # ------------------------------------ #
> options.bounds=[1,2;1,2]
> [f,p,kvg,iter,corp,covp,covr,stdresid,Z,r2]=leasqr(x,y,pin,F,.0001,20,ones(length(y),1),.001*ones(size(pin)),"dfdp",options);
> # ------------------------------------ #
> 
> 'options' is a positional parameter.
> 
> The parameters before 'options' cannot be left out and need to be explicitly
> set to their defaults. The defaults can be found in 'help leasqr'

In addition, "bounds" must be a field of the "options" structure and
can not be given as a separate argument as in your first example.

Nice you got it working. The constraints feature is new, if something
should go wrong don't hesitate to speak up.

Note please that Octave Forge has an extra mailing list, which
probably should preferentially be used for everything which regards
packages. You could miss some announcements if you are not subscribed
there.

Olaf


reply via email to

[Prev in Thread] Current Thread [Next in Thread]