Friday, April 17, 2009

Poster using LaTeX

This is the style I like: http://www.acronymchile.com/poster.html

Linux on laptop

This article compares performance & experience of five Linux distros on laptop and picks Mint as the best one: http://www.laptopmag.com/review/software/what-flavor-of-linux-is-right-for-you.aspx?pid=1

Playing .ape music under Linux

I am pleasantly surprised to find out that Mplayer can play .ape format music.

Monday, April 13, 2009

Rjags on 64-bit Linux

Use this: install.packages("rjags",configure.args="--with-jags-lib=/usr/local/lib")

Sunday, April 12, 2009

Best introduction to Bayesian statistics

Chapter 3 of Scott Lynch's book "Introduction to applied Bayesian statistics and estimation for social scientists" is the best introductory materials of the Bayesian statistics.

JAGS in R

Here is a helpful post: http://www.stat.columbia.edu/~cook/movabletype/archives/2009/02/our_new_r_packa.html

Saturday, April 11, 2009

Rebuild R libraries for the new version

After upgrading to a new version of R, type "update.packages(checkBuilt =TRUE, ask=FALSE)" to rebuild all the libraries currently present in the system.
To install from Gary King's repository, just type "install.packages("Zelig", repos = "http://gking.harvard.edu")"

To build R, use "./configure --enable-R-shlib" or

./configure --enable-R-shlib CXXFLAGS="-g -O3" CFLAGS="-g -O3"
or
./configure --enable-R-shlib  --with-blas="-lptf77blas -lpthread -latlas" CXXFLAGS="-g -O3"

With OpenBLAS:

./configure --enable-R-shlib  --with-blas="-lpthread -lopenblas" CXXFLAGS="-g -O3"

Or with Intel MKL:

./configure --enable-R-shlib --enable-threads=posix --with-lapack --with-blas="-I$MKLROOT/include -L$MKLROOT/lib/intel64 -lmkl_gf_lp64 -lmkl_gnu_thread -lmkl_lapack -lmkl_core -liomp5 -lpthread" CXXFLAGS="-g -O3"


In case R cannot find the tcltk files, use this " ./configure --enable-R-shlib --with-tcl-config=/usr/lib/tcl8.5/tclConfig.sh --with-tk-config=/usr/lib/tk8.5/tkConfig.sh". This suddenly became necessary when I tried to compile the release candidate version of R 2.14 today. The solution was provided by this blog post.

This may yield even better results: ./configure --enable-R-shlib --with-tcl-config=/usr/lib/tcl8.5/tclConfig.sh --with-tk-config=/usr/lib/tk8.5/tkConfig.sh --with-blas="-lptf77blas -lpthread -latlas"

To fulfill build dependency, use "sudo apt-get build-dep r-cran-rgl"

http://wiki.r-project.org/rwiki/doku.php?id=getting-started:installation:debian

==================================================

MKL_LIB_PATH=/opt/intel/composer_xe_2013.4.183/mkl/lib/intel64

OMP_LIB_PATH=/opt/intel/composer_xe_2013.4.183/compiler/lib/intel64

export LD_LIBRARY_PATH=${MKL_LIB_PATH}:${OMP_LIB_PATH}

MKL=" -L${MKL_LIB_PATH}   -L${OMP_LIB_PATH} -Wl,--start-group -lmkl_gf_lp64 -lmkl_intel_thread -lmkl_core -Wl,--end-group -liomp5 -lpthread"


./configure --enable-R-shlib --enable-threads=posix --with-blas="$MKL" --with-lapack CXXFLAGS="-g -O3"

Thursday, April 09, 2009

Open source mind mapping

Mind mapping is an important part of research. As far I know, there are two open source options: freemind and xmind. I use both but prefer xmind because it is built on the Eclipse framework and is more elegant than freemind at the moment. If I need more functionalities such as exporting to Word or Powerpoint, I can upgrade to the professional edition with less than $50 per year.

I chose to install it on top my existing Eclipse instead of using the .deb binary file so that I do not have to leave Eclipse just for mind mapping.

Thursday, April 02, 2009

Sams Teach Yourself Emacs in 24 Hours

http://www.emacs.uniyar.ac.ru/doc/em24h/index.htm

Good reference for Emacs.

Counter