Re: [R] Basic loop programming

2013-01-09 Thread MacQueen, Don
Yes, R is a different language, and has different syntax and different built-in functions, so, yes it works differently. If you want to do it the same way in R as in that other language, you have to use a different method for constructing the variable names inside the loop. Here's an example, usin

Re: [R] Basic loop programming

2013-01-09 Thread arun
eb 132.5 35.0 3.785714 #2 2012   Feb 119.0 37.5 3.17 #3 2011   Jan 137.5 37.5 3.67 #4 2012   Jan 125.0 30.0 4.17 #5 2012   Mar 127.5 39.0 3.269231 A.K. - Original Message - From: Paolo Donatelli To: r-help@r-project.org Cc: Sent: Wednesday, January 9, 201

Re: [R] Basic loop programming

2013-01-09 Thread Jose Iparraguirre
alf Of Paolo Donatelli Sent: 09 January 2013 16:03 To: r-help@r-project.org Subject: [R] Basic loop programming Hi all, newbie question: I am trying to set up a very simple loop without succeeding. Let's say I have monthly observation of two variables for a year - Sales_2012_01, Sales_2012_02, Sa

Re: [R] Basic loop programming

2013-01-09 Thread PIKAL Petr
Hi > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of Paolo Donatelli > Sent: Wednesday, January 09, 2013 5:03 PM > To: r-help@r-project.org > Subject: [R] Basic loop programming > > Hi all, > > n

[R] Basic loop programming

2013-01-09 Thread Paolo Donatelli
Hi all, newbie question: I am trying to set up a very simple loop without succeeding. Let's say I have monthly observation of two variables for a year - Sales_2012_01, Sales_2012_02, Sales_2012_03, (total sales for jan 2012,feb 2012, etc.) - Customers_2012_01, Customers_2012_02, (