(stolen from here)
How-to install R on CentOS
How-to install the open source statistical tool and relative developement libraries R on CentOS release 4 and 5.
Personally I’ve tried it successfully on CentOS 5.
CentOS today does not provide any build of this tool in it’s official and semi-official repositories but, luckily the R-project itselfs provides the binaries for the most common GNU/Linux distributions (and for Windows or Mac OS X, alongside with the sources) on it’s mirror network.
There you can find binary rpms and also yum metadata, so you can create a .repo file for and organic and integrated use of those inside the YUM package manager.
So here’s the R.repo file I’ve created for myself:
[R-project] name=R project for Statistical Computing repository baseurl=http://rm.mirror.garr.it/mirrors/CRAN/bin/linux/redhat/el5/i386 failovermethod=priority enabled=1 gpgcheck=0 priority=15
Maybe it’s necessary a quick note on gpgcheck=0 since I was not able to find the GPG key of the rpms (maybe they’re not available ???) and on priority=15 since i use yum-priorities to protect the official core of the distro.