I have a large data.frame loaded to memory in an R instance on one machine, and I'm using Rserve to allow access to this data from remote clients. I would like to be able to remotely make changes to the data.frame, like adding a column or changing a value, and I would like these changes to be available to other clients.
# server side
> xxx<-data.frame(a=1:3,b=4:6)
> run.Rserve(port = 6311, ...)
# client side
> cc<-RSconnect(port=6311, ...)
> RSeval(cc,'xxx$c<-7:9')
> RSeval(cc,'xxx')
a b c
1 1 4 7
2 2 5 8
3 3 6 9
However, when I connect with a second client it does not see the changes:
# another client
> cc2<-RSconnect(port=6311, ...)
> RSeval(cc2,'xxx')
a b
1 1 4
2 2 5
3 3 6
When the server is stopped the internal data is also unchanged. The changes are only available to the client that made them, not really what I need.
Is there some way to make this work?