From dmurdoch at pair.com  Fri Jul 18 20:08:40 2003
From: dmurdoch at pair.com (Duncan Murdoch)
Date: Sat Jul 19 01:08:37 2003
Subject: [Rd] Strategies for S-PLUS compatibility?
In-Reply-To: <32pfhvchub55ql2a7j6u39m747tp53bheq@4ax.com>
References: <32pfhvchub55ql2a7j6u39m747tp53bheq@4ax.com>
Message-ID: <5vughvkppni828vcra00uub2dg3ar13eu2@4ax.com>

On Fri, 18 Jul 2003 08:14:53 -0400, you wrote:

>I'd like to give a copy of an R package to someone using S-PLUS.  It
>doesn't just run as-is, it'll need changes.  Has anyone written any
>general guidelines on ways to port in that direction?  

The package in question is "orientlib", the one I recently put on
CRAN.  It uses S version 4 methods, and those seem to be the problem.

There are a number of small differences that cause trouble (e.g. the
first argument in weighted.mean is named "y" in S-PLUS, but "x" in R,
so I get complaints when converting it to a method), and something
that's beyond my debugging abilities:  calling a method appears to
call the default method instead of the appropriate one based on the
signature.  Calling getMethod to diagnose the problem also appears to
call the default method !?!

This is all in S-PLUS 6.1 for Windows.  

Obviously R-help is the wrong place to be asking for this sort of
detailed help; I guess I'll try over in s-news.

Duncan Murdoch


[Rd] Strategies for S-PLUS compatibility?
Duncan Murdoch