From hpages at fredhutch.org  Sat Dec 17 02:07:10 2016
From: hpages at fredhutch.org (=?UTF-8?B?SGVydsOpIFBhZ8Oocw==?=)
Date: Fri, 16 Dec 2016 17:07:10 -0800
Subject: [Rd] syntax difference clusterExport in parallel and snow
In-Reply-To: <ea0a9ca1-39bd-1407-3458-de4cd5259596@stats.ox.ac.uk>
References: <CAErODj-ZqYvuvvS3wdF7L2O7-JJwSi7-wi6Jtp4UPmrZ4j+aQA@mail.gmail.com>
	<ea0a9ca1-39bd-1407-3458-de4cd5259596@stats.ox.ac.uk>
Message-ID: <96989ce0-87c9-cd8d-edd2-a057b9a1ddef@fredhutch.org>

On 12/13/2016 09:33 AM, Prof Brian Ripley wrote:
> On 13/12/2016 17:05, Paul Johnson wrote:
>> We got some errors and eventually figured out that
>> parallel::clusterExport second argument is "varlist" while in
>> snow::clusterExport it is "list".
>>
>> The user had loaded parallel first, but did something else which
>> inadvertently loaded snow, then clusterExport failed because we had
>> "varlist" and not "list".
>>
>> Are these different on purpose?
>
> Yes.
>
> ('list' is an unhelpful name for an argument that is not a list.)
>
>

Yes 'list' is a misleading name for a character vector. OTOH I guess
snow::clusterExport() was just following the lead of base::save() and
base::remove() on this.

I don't see 'varlist' as being much less confusing though: it still
suggests that the thing is a list and parallel::clusterExport() is
now inconsistent with snow::clusterExport(). So it doesn't really
address the 1st problem and introduces a new one. Sounds like using
a plural form instead of the "list" prefix would be less confusing
e.g. 'vars', 'varnames', 'objnames' or something like that.

H.

-- 
Herv? Pag?s

Program in Computational Biology
Division of Public Health Sciences
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N, M1-B514
P.O. Box 19024
Seattle, WA 98109-1024

E-mail: hpages at fredhutch.org
Phone:  (206) 667-5791
Fax:    (206) 667-1319



[Rd] syntax difference clusterExport in parallel and snow
=?UTF-8?B?SGVydsOpIFBhZ8Oocw==?=