<- 1000
n <- 5
m <- m - 1
dof <- rchisq(n, dof)
chisq <- hist(chisq, breaks = 100, plot = FALSE)
h $counts <- h$counts / sum(h$counts)
hplot(h, ylab = "relative frequency", axes = FALSE)
axis(1)
axis(2)
相対頻度のヒストグラム
statistics
graphics
頻度でも密度でもなく
hist()
は折れ線を描く函数だが、plot = FALSE
で統計のみにする。 頻度を総数で割り、相対頻度にしてplot()
で描画する。