[R-SIG-Mac] install.packages

Don MacQueen macq at llnl.gov
Wed Jul 19 06:39:29 CEST 2006


If this explanation is correct (I haven't attempted to verify) then try adding
    type='source'
to the invocation of install.packages().

-Don

At 8:12 PM -0700 7/18/06, Seth Falcon wrote:
>Herve Pages <hpages at fhcrc.org> writes:
>
>>  Hi,
>>
>>  Does anyone know why, on MacOS X, install.packages() is issuing this
>>  warning:
>>
>>    number of rows of result
>>            is not a multiple of vector length (arg 2) in: cbind(1, res0,
>>  Repository = repos)
>>
>>  when it's given a repos vector of length >= 4?
>
>Actually, I think this occurs when a repository doesn't have any OSX
>packages.

In binary format, that is.

>  The lindsey repository has no OSX packages AFAIK.  You can
>reproduce the warning using repos=repos[c(1, 5)].
>
>The warning comes from available.packages (packages.R:67).
>
>I suspect something like the following would be a reasonable fix:
>
>--- a/src/library/utils/R/packages.R
>+++ b/src/library/utils/R/packages.R
>@@ -64,8 +64,10 @@ available.packages <-
>                  on.exit()
>              } # end of download vs cached
>          } # end of localcran vs online
>-        res0 <- cbind(res0, Repository = repos)
>-        res <- rbind(res, res0)
>+        if(length(res0)) {
>+            res0 <- cbind(res0, Repository = repos)
>+            res <- rbind(res, res0)
>+        }
>      }
>
>I'm pretty sure this would come up for other platforms, it is just
>more common for CRAN-style repositories to not have any OS X binaries
>available.
>
>Best,
>
>+ seth
>
>_______________________________________________
>R-SIG-Mac mailing list
>R-SIG-Mac at stat.math.ethz.ch
>https://stat.ethz.ch/mailman/listinfo/r-sig-mac


-- 
---------------------------------
Don MacQueen
Lawrence Livermore National Laboratory
Livermore, CA, USA



More information about the R-SIG-Mac mailing list