{{outline}} !!!相関と回帰式 !相関係数 > cor(Type, Token) [1] 0.889026 !相関関係の検定 > cor.test(Type, Token) Pearson's product-moment correlation data: Type and Token t = 32.665, df = 283, p-value < 2.2e-16 alternative hypothesis: true correlation is not equal to 0 95 percent confidence interval: 0.8618637 0.9111023 sample estimates: cor 0.889026 !相関関係の散布図と回帰直線(xとyが入れ替わる点に注意) > plot(Type, Token) > abline(lm(Token ~ Type))