Sorry, the previous had a bug and was quite ugly. This is a bit better:
--
function (x, y = NULL, type = p, xlim = NULL, ylim = NULL,
log = , main = NULL, sub = NULL, xlab = NULL, ylab = NULL,
ann = par(ann), axes = TRUE, frame.plot = axes, panel.first = NULL,
panel.last = NULL,
It is really strange that the delayedAssign is evaluated in the environment
it is called from, and thus can have side effects.
so
x=2
y=3
delayedAssign(x, {y - 7; y+3})
gives
x
[1] 10
y
[1] 7
Both x and y changed.
More intuitive would have been the behavior
x=2
y=3
delayedAssign(x, local({y -
Simon Urbanek wrote
More intuitive would have been the behavior
delayedAssign(x, local({y - 7; y+3}) )
which only changes x.
That is questionable - I think it is more logical for both environments to
be the same as default. Just think if it -- the point here is to access
lazy
I have also often longed for such a shortcut.
The problem is that most often, my plot statements do not look like this:
plot(y)
but instead like this:
plot( some_very_long_expression_involving(x),
some_other_very_long_expression_involving(x) )
And since I'm working with a GUI, I often go up and
I'm replying here to quite an old thread started by me.
I think the dimnames facility is underused in R.
I'm currently using a 5-dimensional array. It is quite cumbersome to have to
write
y[0]
Since the array does have dimnames, I would like to be able to say instead
y[tree=0]
Below is a
I wrote the interface between R and TeXmacs. Recently, I added tab
completion. However, there is one slight problem. In order to enable easy
interaction with R, I (I.e. my program) interact with the command-line
interface. This means that the user can invoke demo(), and then R will
interact with
Another message about the R to TeXmacs interface.
1. Graphics
The TeXmacs interface allows the user to directly insert graphics into the
session.
Since I am not very familiar with programming for R, I implemented the
interaction with graphics in a very primitive way. It was two modes of
Simon Urbanek wrote:
On Sep 7, 2010, at 2:06 PM, ghostwheel wrote:
a-c(3,4
and then R will respond with '+'.
The problem is this: the way I implemented tab completion is calling an R
function that creates the completion. But, while in the middle of user
input, I can't call
Simon Urbanek wrote:
I don't know the mechanics of the actual inserting in TeXmac but it
would be trivial to simply create a copy of the plot as EPS (or whatever
is needed) at the time of insertion. See dev.copy2eps() for a function
that does exactly that.
Great. It works much
Simon Urbanek wrote:
It doesn't really matter where the R is as long as you have some way of
getting at the results. You are still leaving us in the dark as of what
exactly you do (technically) so there is not much detail we can provide...
Sorry, I'll try to provide more detail:
I
10 matches
Mail list logo