Articles by Xianjun Dong

DTW: dynamic time warping 动态时间规整

September 18, 2011 | Xianjun Dong

Basically, DTW (dynamic time warping) is an algorithm to output cumulative distance of two time sequences, which is widely used e.g. for classification and clustering.For example, when using k-mean for clustering, we can use DTW as distance function. Here is one of such nice instances (using R: http://... [Read more...]

Density curve of histogram plot in R

September 1, 2011 | Xianjun Dong

Ref: To add density curve on a histogram, like the green curve above, use code below:#plot the distributionhist(slope, breaks=1000, freq=F, main=main, xlab="Slope Value (percent)", ... [Read more...]

Add text aligned to legend in R plot

September 1, 2011 | Xianjun Dong

What I meant is to add text on a R plot when there is already legend on it. Like the left plot in above figure, another piece of text was put exactly below the legend "Pearson'r ...RMSE = 1.9". Here is the code for that: l=legend("topleft", paste(... [Read more...]
1 2 3

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)