It seems indeed that it is a locale issue :

> Sys.getlocale()
[1] 
"LC_CTYPE=fr_FR.UTF-8;LC_NUMERIC=C;LC_TIME=fr_FR.UTF-8;LC_COLLATE=fr_FR.UTF-8;LC_MONETARY=C;LC_MESSAGES=fr_FR.UTF-8;LC_PAPER=fr_FR.UTF-8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=fr_FR.UTF-8;LC_IDENTIFICATION=C"


> install.packages("toto")
Erreur dans sprintf(gettext(fmt, domain = domain), ...) : 
  format incorrect '%
(ca' ; utilisez le format %s pour les objets caractères

> Sys.setlocale("LC_MESSAGES","C")
[1] "C"

> install.packages("toto")
Installing package(s) into 
‘/home/username/R/x86_64-pc-linux-gnu-library/2.12’
(as ‘lib’ is unspecified)
--- Please select a CRAN mirror for use in this session ---
Loading Tcl/Tk interface ... done
Warning message:
In getDependencies(pkgs, dependencies, available, lib) :
  package ‘toto’ is not available

Many thanks for the hint!


 
________________________________
Dr Vincent Chouraki
Assistant hospitalier universitaire
Service d'épidémiologie régional
CHRU de Lille, France





________________________________
De : Prof Brian Ripley <rip...@stats.ox.ac.uk>

Cc : R-help <r-help@r-project.org>
Envoyé le : Mar 19 octobre 2010, 13h 47min 58s
Objet : Re: [R] [R 2.12] install.packages() with no lib argument does not work

Looks like this may be a problem in the French translations.  Please 
try with LANGUAGE=en.

On Tue, 19 Oct 2010, vincent chouraki wrote:

> Dear R users,
>
> I have just upgraded R from 2.11 to 2.12 on Ubuntu 9.04 (see more informations
> at the end) from the cran apt-get repository. One of the new things concerning
> the install.packages() function is stated here :
>
>
> install.packages() and remove.packages() with lib unspecified and       
>multiple
> libraries in .libPaths() inform the user of the library       location used 
>with
> a message rather than a warning.
>
> I am in this case where .libPaths() has multiple libraries:
>
>> .libPaths()
> [1] "/home/username/R/x86_64-pc-linux-gnu-library/2.12"
> [2] "/usr/local/lib/R/site-library"
> [3] "/usr/lib/R/site-library"
> [4] "/usr/lib/R/library"
> [5] "/usr/lib64/R/library"
> and install.packages() gives me an error when lib is not given:
>
>> install.packages("lattice")
> Erreur dans sprintf(gettext(fmt, domain = domain), ...) :
>  format incorrect '%
> (ca' ; utilisez le format %s pour les objets caract?res
>
>> install.packages("toto")
> Erreur dans sprintf(gettext(fmt, domain = domain), ...) :
>  format incorrect '%
> (ca' ; utilisez le format %s pour les objets caract?res
>
>
> whatever package name is given.
>
> For the time being, I am using :
>
>> install.packages("lattice", "")
>
> and it works fine.
>
> Is this the new way of using the install.packages() function or an error?
>
> Best regards,
>
>> sessionInfo()
> R version 2.12.0 (2010-10-15)
> Platform: x86_64-pc-linux-gnu (64-bit)
>
> locale:
> [1] LC_CTYPE=fr_FR.UTF-8       LC_NUMERIC=C
> [3] LC_TIME=fr_FR.UTF-8        LC_COLLATE=fr_FR.UTF-8
> [5] LC_MONETARY=C              LC_MESSAGES=fr_FR.UTF-8
> [7] LC_PAPER=fr_FR.UTF-8       LC_NAME=C
> [9] LC_ADDRESS=C               LC_TELEPHONE=C
> [11] LC_MEASUREMENT=fr_FR.UTF-8 LC_IDENTIFICATION=C
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods   base
>
> other attached packages:
> [1] fortunes_1.4-0
>
> usern...@computer:~$ uname -a
> Linux computer 2.6.28-19-generic #65-Ubuntu SMP Thu Sep 16 14:24:42 UTC 2010
> x86_64 GNU/Linux
> usern...@computer:~$ cat /etc/lsb-release
> DISTRIB_ID=Ubuntu
> DISTRIB_RELEASE=9.04
> DISTRIB_CODENAME=jaunty
> DISTRIB_DESCRIPTION="Ubuntu 9.04"
>
>
> ________________________________
> Dr Vincent Chouraki
> Assistant hospitalier universitaire
> Service d'?pid?miologie r?gional
> CHRU de Lille, France
>
>
>
>     [[alternative HTML version deleted]]
>
>

-- 
Brian D. Ripley,                  rip...@stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595



      
        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to