[R] Uniroot - error
peter dalgaard
pdalgd at gmail.com
Tue May 10 12:10:58 CEST 2011
On May 6, 2011, at 16:37 , Joshua Wiley wrote:
> On Fri, May 6, 2011 at 6:33 AM, CarJabo <carly_tse at hellokitty.com> wrote:
>> sorry I am not asking someone to do my homework, as I have finished all the
>> procedure. I am just wondering why this technical error occurs, so I can fix
>> it myself.
>
....
> If whatever institution you are taking this at simply gives
> assignments, grades them and penalizes for plagiarism without having
> any instructors or teachers, I recommend moving to an institution
> where classes are taught by someone who can answer questions etc. As
> Dr. Murdoc (and the posting guide) said and say, R-help is not for
> homework.
The occasional hint might slip though the iron-cladding once in a while though.
In this case, learning how to use options(error=recover) might be relevant. Turn it on, let the error occur and do the post mortem. The culprit is obviously that f(2) isn't positive. Unless F has turned out all-zero or has negative elements, you need a larger value of 2, otherwise, find out why F is weird.
--
Peter Dalgaard
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: pd.mes at cbs.dk Priv: PDalgd at gmail.com
More information about the R-help
mailing list