Thanks Paul. I thought constrOptim does not do equality. I will check again.

A concrete example for finding a solution based on a target value instead of
min or max would be something like this: let's say I am trying exponential
smoothing on a time series and would like to find a solution for the
smoothing constant that instead of minimizes the root mean square error
(RMSE), it targets a particular value of RMSE. Is this possible in R?


On 1/9/08, Paul Smith <phhs80@gmail.com> wrote:
>
> On Jan 9, 2008 1:14 PM, tom soyer <tom.soyer@gmail.com> wrote:
> > Thanks Paul. yes, with equality constraints. What are "friends"? I read
> the
> > document for optim, but still could not figure out how to do this. Do
> you
> > just set the lower bound equal to the upper bound?
>
> constrOptim is a friend of optim. See ?constrOptim.
>
> Could you please provide a concrete example of an optimization problem
> that you would like R solving it?
>
> > Also, is it possible to ask R to search for a solution based on a target
> > value instead of min and max? Is there a function like that in R?
>
> Could you please provide a concrete example?
>
> Paul
>
>
>
> > On 1/9/08, Paul Smith <phhs80@gmail.com> wrote:
> > >
> > >
> > >
> > > On Jan 9, 2008 4:01 AM, tom soyer <tom.soyer@gmail.com> wrote:
> > > > I noticed that R has a few bound-constrained nonlinear min and max
> > solvers,
> > > > such as optim, nlm, etc. But I could not find a constrained min and
> max
> > > > solver that is not LP. Does this mean R do not have this capability?
> It
> > is
> > > > hard to believe that R may not be as advanced as Excel in certain
> > areas...
> > > > Maybe it's there but I missed it? Does anyone know?
> > >
> > > Do you mean optimization solvers for nonlinear problems with equality
> > > constraints? If so, you can use optim and friends with penalties to
> > > incorporate equality constraints.
> > >
> > > Paul
> > >
> > >
> > > ______________________________________________
> > > R-help@r-project.org mailing list
> > > https://stat.ethz.ch/mailman/listinfo/r-help
> > > PLEASE do read the posting guide
> > http://www.R-project.org/posting-guide.html
> > > and provide commented, minimal, self-contained, reproducible code.
> > >
> >
> >
> >
> > --
> > Tom
>
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



-- 
Tom

	[[alternative HTML version deleted]]


