Re: [R] Translating a basic Python script into R

2013-12-29 Thread sun shine
On 29/12/13 10:45, YuHong wrote: In my opinion, the best usages of Python and R should be for different type of tasks respectively. For example, Python is good for automating miscellaneous tasks, while R is good for list data processing and statistical modelling. Therefore when you become m

Re: [R] Translating a basic Python script into R

2013-12-29 Thread YuHong
, you shall not use the two for exactly the same thing. -Original Message- From: sun shine Sent: Sunday, December 29, 2013 5:32 PM To: r-help@r-project.org Subject: Re: [R] Translating a basic Python script into R Hi Ista On 28/12/13 23:06, Ista Zahn wrote: Hi, I don't se

Re: [R] Translating a basic Python script into R

2013-12-29 Thread sun shine
Hi Ista On 28/12/13 23:06, Ista Zahn wrote: Hi, I don't see any nested conditions in the python code... A direct translation in R looks almost the same, except that you need to group using parentheses and brackets instead of whitespace, and there is no += in R (at least not that I'm aware of).

Re: [R] Translating a basic Python script into R

2013-12-28 Thread Ista Zahn
Hi, On Sat, Dec 28, 2013 at 10:46 AM, sun shine wrote: > Hi > > I am attempting to translate some of the models that Donella Meadows wrote > about in her book "Thinking in systems" into code. Originally, I had wanted > to do this in Python, but thought that it would be fun to see if it is > feasi

[R] Translating a basic Python script into R

2013-12-28 Thread sun shine
Hi I am attempting to translate some of the models that Donella Meadows wrote about in her book "Thinking in systems" into code. Originally, I had wanted to do this in Python, but thought that it would be fun to see if it is feasible to do so in R, especially given the plotting capacity of R.