Re: [R] how to skip part of the code

2013-03-21 Thread David Winsemius
1:10) < 0] integer(0) Another potential source of error would be passing an alphabetic value: "e" > 0 #[1] TRUE -- David. > > Thanks for the help guys! > > Andras > > --- On Wed, 3/20/13, Robert Baer wrote: > > > From: Robert Baer > Subject: Re

Re: [R] how to skip part of the code

2013-03-21 Thread Andras Farkas
r the help guys!   Andras --- On Wed, 3/20/13, Robert Baer wrote: From: Robert Baer Subject: Re: [R] how to skip part of the code To: "PIKAL Petr" Cc: "Andras Farkas" , "r-help@r-project.org" Date: Wednesday, March 20, 2013, 9:27 AM On 3/20/2013 8:21 AM, P

Re: [R] how to skip part of the code

2013-03-21 Thread PIKAL Petr
r-help@r-project.org Subject: Re: [R] how to skip part of the code Dear Pikal and Robert, thanks for the help, I guess trying the if function is worth it, and indeed, it works for the example I provided. Unfortunatelly though I am not getting the expected results with my actual code, which is a

Re: [R] how to skip part of the code

2013-03-20 Thread David Winsemius
Are you perhaps dealing with a samll non-zero 'e' that prints as zero at the console? Check Faq 7.31. Also: ?all.equal ?zapsmall -- David. --- On Wed, 3/20/13, Robert Baer wrote: From: Robert Baer Subject: Re: [R] how to skip part of the code To: "PIKAL Petr"

Re: [R] how to skip part of the code

2013-03-20 Thread arun
e - From: Andras Farkas To: r-help@r-project.org Cc: Sent: Wednesday, March 20, 2013 9:11 AM Subject: [R] how to skip part of the code Dear All,   another quick question, this one is on skipping part of my code, so let us say:   a <-5 b <-2 e <-0   d <-a+b f <-a-b   what I wo

Re: [R] how to skip part of the code

2013-03-20 Thread Andras Farkas
of the model in OpenBUGS, which is what is happening currently with the way it is written here. Any thoughts on how to completiley "ignorre" a that line or chunk?   thanks,   Andras --- On Wed, 3/20/13, Robert Baer wrote: From: Robert Baer Subject: Re: [R] how to skip part of the

Re: [R] how to skip part of the code

2013-03-20 Thread Robert Baer
On 3/20/2013 8:21 AM, PIKAL Petr wrote: Hi -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- project.org] On Behalf Of Andras Farkas Sent: Wednesday, March 20, 2013 2:11 PM To: r-help@r-project.org Subject: [R] how to skip part of the code Dear All

Re: [R] how to skip part of the code

2013-03-20 Thread PIKAL Petr
Hi > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of Andras Farkas > Sent: Wednesday, March 20, 2013 2:11 PM > To: r-help@r-project.org > Subject: [R] how to skip part of the code > > Dear All, >

[R] how to skip part of the code

2013-03-20 Thread Andras Farkas
Dear All,   another quick question, this one is on skipping part of my code, so let us say:   a <-5 b <-2 e <-0   d <-a+b f <-a-b   what I would like to do is to have R NOT to calculate the value for d in case the value of e equals to zero (essentially skip that "chunk"), but instead move on to c