Skip to content

[R-pkg-devel] Package check help: Package required but not available

4 messages · David Stanley, Michael Dewey, Joris Meys +1 more

#
Hi Everyone,

I?m new to this list but hopefully you can help me.

I?m working on updating my apaTables package (most recent code: https://github.com/dstanley4/apaTables)

However, I?m encountering problems passing the CRAN check because of a package I use (MBESS). MBESS is available on all platforms except r-patched-solaris-x86 (see https://cran.r-project.org/web/checks/check_results_apaTables.html)

To work around this I did three things that have not worked.

1) I modified the DESCRIPTION file. I moved MBESS from Imports to Suggests

2) I manipulated a flag (show.confidence.interval) in my file apaDvalueTable.R show that it is always FALSE if the following is FALSE: requireNamespace("MBESS", quietly = TRUE) . That is, if the package is not there do no calculate the confidence intervals that require it. But I still fail the check. Is this perhaps because I didn?t wrap the MBESS command on line 97 with an ?if? using requireNamespace? This command will never be executed without the package though because of the flag.

3) I also wrapped a command that uses MBESS in apaRegressionTable.R (line 276) that uses MBESS.

Any help much appreciated in resolving this "Package required but not available? problem.

(Detailed CRAN message below. Fixing the Notes issues are easy.)

Cheers,
David



David Stanley, PhD | Associate Professor
Department of Psychology | University of Guelph
4002 MacKinnon | 50 Stone Rd E | Guelph, ON | N1G 2W1
dstanley at uoguelph.ca<mailto:dstanley at uoguelph.ca>  | 519-824-4120 Ext. 58590
uoguelph.ca/psychology/users/david-stanley<http://uoguelph.ca/psychology/users/david-stanley>
@dstanley4


Dear maintainer,

package apaTables_2.0.1.tar.gz does not pass the incoming checks automatically, please see the pre-test at:
<https://win-builder.r-project.org/incoming_pretest/180301_161113_apaTables_201/00check.log>
Status: 2 NOTEs

Current CRAN status: ERROR: 1, OK: 11
See: <https://CRAN.R-project.org/web/checks/check_results_apaTables.html>

Please fix all problems and resubmit a fixed version via the webform.
If you are not sure how to fix the problems shown, please ask for help on the R-package-devel mailing list:
<https://stat.ethz.ch/mailman/listinfo/r-package-devel>
If you are fairly certain the rejection is a false positive, please reply-all to this message and explain.

More details are given in the directory:
<https://win-builder.r-project.org/incoming_pretest/180301_161113_apaTables_201>
The files will be removed after roughly 7 days.


Best regards,
CRAN teams' auto-check service
#
Dear David

I am afraid R does not know what your flag is doing so you should try 
wrapping the command as you suggested.

Michael
On 01/03/2018 16:05, David Stanley wrote:

  
    
  
#
Hi David,

When looking at apaDvalueTable.R, there's nothing that prevents the
MBESS::ci.msd() call to be executed when show.conf.interval  is FALSE. Even
then the function will calculate it, just not show the result. So running
your example on Solaris will still give you an error. You'll have to add an
extra condition to prevent this.

On a sidenote: please use message() instead of cat() to send messages to
the user. Then anyone who doesn't want to see them (eg bcs they do a
simulation) can simply use suppressMessages() for that.

Cheers
Joris
On Thu, Mar 1, 2018 at 5:05 PM, David Stanley <dstanley at uoguelph.ca> wrote:

            

  
    
#
On Thu, 2018-03-01 at 16:05 +0000, David Stanley wrote:
David, I think you are misinterpreting the message you are getting. 

The fact that the MBESS package is not available on Solaris is not your
fault and is not something you should have to work around. In fact, the
 problem is not even with the MBESS package, but with the rpf package
through the chain of dependencies:

ApaTables -> MBESS -> OpenMx -> rpf

Note that the message about the lack of availability of MBESS is for
the *current* version of Apatables on CRAN, (1.5.1), not the new
version that your are uploading (2.0.1).

The issues that require fixing are for the incoming checks, that take
place on Windows, i.e. the NOTEs that you say are easily fixed.
Martyn