[EMAIL PROTECTED] (i.e. I) wrote:
> 3. Modify substitute() so that it strips source attributes (or
anything
> else apparently visible that it will not manipulate) from objects.
> Sorry folks, too dangerous. (I concede this appears to be a bit of an
> overkill, too.)
Peter Dalgaard responded:
ll Venables.
>>
>> -Original Message-----
>> From: Peter Dalgaard [mailto:[EMAIL PROTECTED]
>> Sent: Friday, 22 December 2006 9:47 PM
>> To: Venables, Bill (CMIS, Cleveland)
>> Cc: r-devel@stat.math.ethz.ch; [EMAIL PROTECTED]
>> Subject: Re: [Rd] substitu
ll Venables.
>>
>> -Original Message-----
>> From: Peter Dalgaard [mailto:[EMAIL PROTECTED]
>> Sent: Friday, 22 December 2006 9:47 PM
>> To: Venables, Bill (CMIS, Cleveland)
>> Cc: r-devel@stat.math.ethz.ch; [EMAIL PROTECTED]
>> Subject: Re: [Rd] substitu
be dangerous in this way, both in the help informaton for options()
> and for substitute().
>
> ?
>
> Bill Venables.
>
> -Original Message-
> From: Peter Dalgaard [mailto:[EMAIL PROTECTED]
> Sent: Friday, 22 December 2006 9:47 PM
> To: Venables, Bill (CMIS, Cleve
Peter Dalgaard [mailto:[EMAIL PROTECTED]
Sent: Friday, 22 December 2006 9:47 PM
To: Venables, Bill (CMIS, Cleveland)
Cc: r-devel@stat.math.ethz.ch; [EMAIL PROTECTED]
Subject: Re: [Rd] substitute creates an object which prints incorrectly
(PR#9427)
[EMAIL PROTECTED] wrote:
> The function &qu
Try issuing the command:
options(keep.source = FALSE)
prior to running the code you displayed to force the actual source,
rather than the source attribute, to be displayed by print when printing
functions.
On 12/21/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> The function "substitute" s
[EMAIL PROTECTED] wrote:
> The function "substitute" seems to fail to make a genuine
> substitution, although the printed verision seems fine. Here is an
> example.
>
>
>> m <- substitute(Y <- function(x) FUN(x+1),
>>
> + list(Y = as.name("y"), FUN = as.name("sin")))
>
>> m
>>
> y
The function "substitute" seems to fail to make a genuine
substitution, although the printed verision seems fine. Here is an
example.
> m <- substitute(Y <- function(x) FUN(x+1),
+ list(Y = as.name("y"), FUN = as.name("sin")))
> m
y <- function(x) sin(x + 1)
> eval(m)
> y
function(x) FUN(x+1)
H