ASA Connect

 View Only
  • 1.  R Mystery

    Posted 07-16-2021 09:58
    Dear R Users in the AmStat Community:

    When I installed the R package, icdpicr, on my pc, it worked fine.
    icdpicr converts ICD-9 and ICD-10 codes to injury severity scores, something that no SAS procedure can do.

    For a project on a secure data enclave, I do not have permission to install R packages.
    The tech support people told me that they installed icdpicr, but I can not access it.
    When I type, packageVersion("icdpicr") on my pc, it gives me 1.01, but when using R on the data enclave, R tells
    me that the package has not been installed.

    Has anyone encountered this problem with an R package?
    If so, how was the problem solved?

    ------------------------------
    Brandy Sinco, BS, MA, MS
    Statistician Senior
    Michigan Medicine
    ------------------------------


  • 2.  RE: R Mystery

    Posted 07-19-2021 06:51
    Hi Brandy,

    My first guess would be that your IT people installed the package in a non-standard location. R has a default search path it uses to find packages. You can see this path by running the.libPaths() function in R.

    If my suspicion is correct, you will need to find out where the package has been installed. Then you can provide this location to the lib.loc argument when calling packageVersion(), library(), or related functions.

    For example, if the package is installed in /home/adent/packages/, then you could load it by running library("icdpicr", lib.loc = "/home/adent/packages").

    Regards,

    ------------------------------
    Kyle M. Lang
    Assistant Professor
    Dept. of Methodology & Statistics
    Utrecht University
    ------------------------------



  • 3.  RE: R Mystery

    Posted 07-19-2021 08:44
    Hi Brandy,
    I'll second Kyle Lang's suggestion.
    This is not uncommon when IT folks are doing their own thing.
    Best,
    Glen

    ------------------------------
    Glen Wright Colopy
    DPhil Oxon
    Data Scientist at Cenduit LLC, Durham, NC
    ------------------------------