Wednesday, April 15, 2009

clues package for clustering evaluation

clues contain the calculation of five different indexes when comparing two cluster/classifications.

adjustedRand(cl1, cl2, randMethod = c("Rand", "HA", "MA", "FM", "Jaccard"))

While the adjustedRandIndex from mclust can only compute for one.

Saturday, April 4, 2009

ggplot2: Great plot libs

Just put up a post first. More details coming up soon.

Wednesday, April 1, 2009

Robust correlations

The traditional correlation measures are not suitable for noisy or those with outliers. Non-parametric methods like Kendall and Spearman can do slightly better job than Pearson but not enough.

The R package robust provides nice robust correlation methods, covRob:

R LINK

Other robust methods can be found here:
Robust Task View

For outlier removal, you may refer to outliers package. Honestly, it's not doing a good job at all.

Tuesday, March 31, 2009

Heatmaps

There are several functions you may employ to get heatmaps:
default heatmap, image

heatmap.2 in gplots package
heatplot in made4 Bioconductor package
heatmap_2, heatmap_plus in Heatplus Bioconductor package

So far heatmap.2 in gplots works best. If you want to plot some covariates use heatmap_plus

The easiest way to define a custom colorPalette is

colorRamPalette(colors)(num_of_interpretation)

Monday, March 30, 2009

Granger Test of Causality

Test whether one time series can predict another
Here's the R link:

R Link

P.S.
notes: sometimes i hate the nomenclature differences in different programming languages:

in R, converting a form into string is the function as.character(), i was looking for a function like toString, string... blah, never got any luck. This reminds me of a simple function of getting the length of an array:

Java: arrayObject.length
Javascript: arrayObject.length
R: length(arrayObject)
Perl: scalar arrayObject
PHP: sizeof(arrayObject)
...

Sunday, March 29, 2009

Thursday, March 26, 2009

Adding Counter to your blog

Blogspot doesn't support page counter, so it's still pretty hard to track how many people have read your blog. However, yo can track with the 3rd party scripts.

Here's a tutorial, but it's not very detailed. What you can to do is here:

Link to tutorial

But before you get started, you need to register a free account on sitemeter:


sitemeter


Then you will have your own page counter! :)