Monthly Archives: November 2007

Convert factors to numbers

November 29, 2007
By

If you have a vector of factors it is easy to get the factor level; however, I always forget how to extract the factor value. I ran into the answer here.> x<-factor(c(round(rnorm(10),2),"A","B",NA))> x 1.61 1.12 1.26 0.09 -0.13 0.16 -0.03 -0.1 0.09 -0.47 A ...

Read more »

Convert factors to numbers

November 29, 2007
By

If you have a vector of factors it is easy to get the factor level; however, I always forget how to extract the factor value. I ran into the answer here. > x<-factor(c(round(rnorm(10),2),"A","B",NA))> x 1.61 1.12 1.26 0.09 -0.13 0.16 -0.03 -0.1 0.09 -0.47 A ...

Read more »

MetWare: metabolomics database project started on SourceForge

November 22, 2007
By

The Applied Bioinformatics at PRI group where I now work in Wageningen and the group of Steffen Neumann in Halle have started the MetWare project on Sourceforge to develop opensource databases for metabolomics data.The databases design will be based on...

Read more »

An R-based genetic algorithm

November 19, 2007
By

During my PhD I wrote a simple but effective genetic algorithm package for R. Because there was a bug recently found, and there is interest in extending the functionality, I have set up a SourceForge project called genalg.The package provides GA support for binary and real-value chromosomes (and integer chromosomes is something that will be...

Read more »

Preparing plots for publication

November 15, 2007
By

The plotting capabilities of R are excellent; however, when I am preparing a figure for publication, I often need to combine multiple plots or add objects (e.g., arrows or text) to an existing plot. While this can be accomplished in R, my patience for ...

Read more »

Preparing plots for publication

November 15, 2007
By

The plotting capabilities of R are excellent; however, when I am preparing a figure for publication, I often need to combine multiple plots or add objects (e.g., arrows or text) to an existing plot. While this can be accomplished in R, my patience for ...

Read more »

Linear panel data models in R: The PLM package

November 10, 2007
By
Linear panel data models in R: The PLM package

The plm package for R lets you run a number of common panel data models, including The fixed effects (or within) estimator The random effects GLS estimator It also allows for general GLS estimation, as well as GMM estimation, and includes a feature for heteroscedasticity consistent covariance estimation. It’s very easy to use, it simply

Read more »