From misc7 at emerose.org  Fri Feb 26 15:01:12 2010
From: misc7 at emerose.org (Ben)
Date: Fri, 26 Feb 2010 08:01:12 -0600
Subject: [Rd] proto and baseenv()
In-Reply-To: <971536df1002260409ud3ca15od596bf7af753d8be@mail.gmail.com>
References: <20100225043854.GA26106@klutometis.wikitex.org>
	<4B8666E0.4070808@TU-Dresden.de>
	<20100225075038.79ca9b63.misc7@emerose.org>
	<4B868B1A.5050409@stats.uwo.ca>
	<20100225194919.00b10700.misc7@emerose.org>
	<20100226022322.GB19263@klutometis.wikitex.org>
	<971536df1002251931r4972bcdes9c6910423fc52af6@mail.gmail.com>
	<20100226041617.GB21674@klutometis.wikitex.org>
	<971536df1002252042q40b9b00do23b24370ea919482@mail.gmail.com>
	<20100226054154.GA23715@klutometis.wikitex.org>
	<971536df1002260409ud3ca15od596bf7af753d8be@mail.gmail.com>
Message-ID: <20100226080112.72341a14.misc7@emerose.org>


> In end it seems that your real beef is with R so perhaps you should
> be using a different language.

In my case you may be right.  I do think there are a million things
wrong with R.  For instance, I was looking for a package that
overcomes two of the problems R IMHO has: namespace pollution and the
lack of an easy-to-use standard object system.

Should I be using R?  I do keep asking myself that same question...

> With respect to proto its really just discussing whether to use
> proto(baseenv(), ...) vs proto(...)

Unfortunately this doesn't fix the problem as was noted earlier:

> z <- 1
> proto(baseenv(), expr={a <- z})$a
Error in eval(expr, envir, enclos) : object "z" not found

> Also, your alternative likely would be unusable due to performance
> whereas proto is fast enough to be usable (see list of applications
> that use it at http://r-proto.googlecode.com/#Applications).  Its
> not as fast as S3 (though sometimes you can get it that fast by
> optimizing your code).  The development version of proto is even
> faster than the current version of proto due to the addition of lazy
> evaluation.

This make sense to me.


-- 
Ben Escoto



[Rd] proto and baseenv()
Ben