简体   繁体   中英

Comparing Kernel Density Estimation plots

I am actually a novice to R and stats.. Could something like this be done in R

Determining the density estimates of two samples ( 2 Vectors )..?? I have done this Using R and obtained 2 density curves for the 2 samples using kernel density estimation ..

Is there anyway to quantitatively compare how similar/Dissimilar the density estimates of 2 samples are..?

I am trying to find out which data sample exhibits has a similar distribution to a particular distribution..

I am using R Language... Can somebody please help..??

You can use Kolmogorov-Smirnov test ( ks.test ) to compare two distributions. Cramer-von-Mises test is another one. There is this PDF Fitting Distributions with R where they also list other tests that are available (although the nortest package that he uses only tests for normality).

Apprentice Queue is right about using the Kolmogorov-Smirnoff test, but I wanted to add a warning: don't use it on its own. You should visually compare the distributions as well, either with two kernel density plots or histograms, or with a qqplot. Human brains are very good at playing spot-the-difference.

您可以尝试计算地球移动器的距离

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM