Re: [R] incrementing for loop by 2

From: Wacek Kusnierczyk <Waclaw.Marcin.Kusnierczyk_at_idi.ntnu.no>
Date: Thu, 24 Jul 2008 16:14:36 +0200

Clark, Jennifer H wrote:
> Dear List-serv members:
> How can I structure a for loop so that it will increment the counter by two using R? I am just looking for a simple example that shows where the incrementing part should go. Thanks!
>
>
for (i in seq(<start>, <end>, by=2)) { ... }

vQ



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. Received on Thu 24 Jul 2008 - 14:25:40 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 24 Jul 2008 - 14:32:13 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive