[R] Correlation ratio
Scot W. McNary
smcnary at charm.net
Thu Jun 28 07:55:12 CEST 2007
# some data
# the summary table
# extract sums of squares
SS <- anova(npk.aov)$"Sum Sq"
# 343.2950000 189.2816667 8.4016667 95.2016667 21.2816667
33.1350000 0.4816667 185.2866667
# eta-squared for factor N
#SS factor N/SS Total
# partial eta-squared for factor N
# SS factor N/(SS Factor N + SS Residuals)
Hope this helps,
suman Duvvuru wrote:
> Hi Bruce,
> correlation ratio (eta) is different from correlation coefficient (rho).
> While correlation coefficient captures only a linear relationship btw
> variables, correlation ratio captures both linear and non-linear
> relationships. It is the defined as the ratio of the variance between
> arrays to the total variance.
> On 6/27/07, Bruce Willy <croero at hotmail.com> wrote:
>> try cor(x, y = NULL, use = "all.obs",
>> method = c("pearson", "kendall", "spearman"))
>> in the R console, you can type "?cor" to get some help on a particular
>> and help.search("correlation") if you do know the keyword
>>> Date: Wed, 27 Jun 2007 18:00:05 -0400
>>> From: duvvuru.suman at gmail.com
>>> To: R-help at stat.math.ethz.ch
>>> Subject: [R] Correlation ratio
>>> I wanted to know how to compute the correlation ratio (eta) between two
>>> variables using R. Is there any function to compute the correlationratio.
>>> Any help will be very much appreciated.
smcnary at charm dot net
More information about the R-help