Hi, If i want to repeat a function, say 100 times, how do i do that? i used the for loop but there's an error somewhere. Thanks shan [[alternative HTML version deleted]]
Please read the posting guide. "there's an error somewhere" is simply not enough to go on. Best, Ista On Sat, Jul 2, 2011 at 9:03 AM, Shantal Bonnick <shantalnb at yahoo.com> wrote:> Hi, > > If i want to repeat a function, say 100 times, how do i do that? i used the for > loop but there's an error somewhere. > > Thanks > shan > ? ? ? ?[[alternative HTML version deleted]] > > ______________________________________________ > R-help at 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. >-- Ista Zahn Graduate student University of Rochester Department of Clinical and Social Psychology http://yourpsyche.org
Your question needs help. Seriously. A) No subject on the Subject line. This makes it difficult to keep track of the replies as the discussion proceeds. B) no example code. This makes it difficult to respond directly, since there is more than one way to "use the for loop". C) No mention of the specific error. Errors can be related to syntax or semantics, or may be due to a misunderstanding of the correct answer. D) No explanation of your intent. Sometimes the best way to compute multiple results is to avoid a for loop entirely, but we need to know what you are trying to accomplish. E) No mention of your computing environment or its configuration. Sometimes the error is related to a particular version of R, and there is a specific easy way to ask R for that information. Please follow the link at the bottom of any R-help list message and learn how to ask a question that can be answered online. --------------------------------------------------------------------------- Jeff Newmiller The ..... ..... Go Live... DCN:<jdnewmil@dcn.davis.ca.us> Basics: ##.#. ##.#. Live Go... Live: OO#.. Dead: OO#.. Playing Research Engineer (Solar/Batteries O.O#. #.O#. with /Software/Embedded Controllers) .OO#. .OO#. rocks...1k --------------------------------------------------------------------------- Sent from my phone. Please excuse my brevity. Shantal Bonnick <shantalnb@yahoo.com> wrote: Hi, If i want to repeat a function, say 100 times, how do i do that? i used the for loop but there's an error somewhere. Thanks shan [[alternative HTML version deleted]] _____________________________________________ 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. [[alternative HTML version deleted]]
On 02/07/2011 14:03, Shantal Bonnick wrote:> Hi, > > If i want to repeat a function, say 100 times, how do i do that? i used the for > loop but there's an error somewhere. > > Thanks > shan > [[alternative HTML version deleted]] >Hi Shan, Could you post the code you're using? Then we can figure out where the error is coming from. Best, James