[R] Rserve and R to R communication
Paul Gilbert
pgilbert at bank-banque-canada.ca
Mon Apr 9 22:05:02 CEST 2007
Matthew Keller wrote:
> Hi Paul,
>
> Thanks for your message, but I'm not 100% clear on your meaning. Could
> you unpack your logic a bit? Is this because two (+) sub-processes
> that are begun at precisely the same time will both have the same
> set.seed value (by default) for any RNG?
That seems a bit unlikely, however, you are changing the pattern of the
random numbers by mixing numbers from generators on different machines
running in parallel. So the numbers you are generating are not according
to the studied properties of the generator you are nominally using.
People who study random number generation worry about this sort of
thing. You would not be able to claim you are using any particular
scheme, which would be a problem if you want to rely on the results or
publish them.
My guess is that the numbers might be quite random, perhaps even hard to
reproduce (which is another problem). But my guess is not something you
would want to claim as authoritative.
Paul Gilbert
>
> Matt
>
> On 4/9/07, Paul Gilbert <pgilbert at bank-banque-canada.ca> wrote:
>> Matthew Keller wrote:
>> > Hi Ramon,
>> >
>> > I've been interested in responses to your question. I have what I
>> > think is a similar issue - I have a very large simulation script and
>> > would like to be able to modularize it by having a main script that
>> > calls lots of subscripts -
>> For simulations you need to worry about the random number generator
>> sequence. I think snow has a scheme for handling this. If you devise
>> your own system then be sure to look after this (non-trivial) detail.
>>
>> Paul Gilbert
>> > but I haven't done that yet because the
>> > only way I could think to do it was to call a subscript, have it run,
>> > save the objects from the subscript, and then call those objects back
>> > into the main script, which seems like a very slow and onerous way to
>> > do it.
>> >
>> > Would Rserve do what I'm looking for?
>> >
>> > On 4/7/07, Ramon Diaz-Uriarte <rdiaz02 at gmail.com> wrote:
>> >
>> >> Dear All,
>> >>
>> >> The "clients.txt" file of the latest Rserve package, by Simon
>> Urbanek,
>> >> says, regarding its R client,
>> >>
>> >> "(...) a simple R client, i.e. it allows you to connect to Rserve
>> from
>> >> R itself. It is very simple and limited, because Rserve was not
>> >> primarily meant for R-to-R communication (there are better ways to do
>> >> that), but it is useful for quick interactive connection to an Rserve
>> >> farm."
>> >>
>> >> Which are those better ways to do it? I am thinking about using
>> Rserve
>> >> to have an R process send jobs to a bunch of Rserves in different
>> >> machines. It is like what we could do with Rmpi (or pvm), but without
>> >> the MPI layer. Therefore, presumably it'd be easier to deal with
>> >> network problems, machine's failures, using checkpoints, etc. (i.e.,
>> >> to try to get better fault tolerance).
>> >>
>> >> It seems that Rserve would provide the basic infrastructure for doing
>> >> that and saves me from reinventing the wheel of using sockets, etc,
>> >> directly from R.
>> >>
>> >> However, Simon's comment about better ways of R-to-R communication
>> >> made me wonder if this idea really makes sense. What is the catch?
>> >> Have other people tried similar approaches?
>> >>
>> >> Thanks,
>> >>
>> >> R.
>> >>
>> >> --
>> >> Ramon Diaz-Uriarte
>> >> Statistical Computing Team
>> >> Structural Biology and Biocomputing Programme
>> >> Spanish National Cancer Centre (CNIO)
>> >> http://ligarto.org/rdiaz
>> >>
>> >> ______________________________________________
>> >> R-help at stat.math.ethz.ch mailing list
>> >> https://stat.ethz.ch/mailman/listinfo/r-help
>> >> PLEASE do read the posting guide
>> http://www.R-project.org/posting-guide.html
>> >> and provide commented, minimal, self-contained, reproducible code.
>> >>
>> >>
>> >
>> >
>> >
>> ====================================================================================
>>
>>
>> La version française suit le texte anglais.
>>
>> ------------------------------------------------------------------------------------
>>
>>
>> This email may contain privileged and/or confidential information,
>> and the Bank of
>> Canada does not waive any related rights. Any distribution, use, or
>> copying of this
>> email or the information it contains by other than the intended
>> recipient is
>> unauthorized. If you received this email in error please delete it
>> immediately from
>> your system and notify the sender promptly by email that you have
>> done so.
>>
>> ------------------------------------------------------------------------------------
>>
>>
>> Le présent courriel peut contenir de l'information privilégiée ou
>> confidentielle.
>> La Banque du Canada ne renonce pas aux droits qui s'y rapportent.
>> Toute diffusion,
>> utilisation ou copie de ce courriel ou des renseignements qu'il
>> contient par une
>> personne autre que le ou les destinataires désignés est interdite. Si
>> vous recevez
>> ce courriel par erreur, veuillez le supprimer immédiatement et
>> envoyer sans délai à
>> l'expéditeur un message électronique pour l'aviser que vous avez
>> éliminé de votre
>> ordinateur toute copie du courriel reçu.
>>
>
>
====================================================================================
La version française suit le texte anglais.
------------------------------------------------------------------------------------
This email may contain privileged and/or confidential inform...{{dropped}}
More information about the R-help
mailing list