Q-Qプロット

Q-Qプロットテンプレート。データの正規性を視覚的に評価。

Q-Q正規性分布
Q-Qプロット

R Code (ggplot2)

library(ggplot2)

# ---- Q-Q Plot ----
# あなたのデータを入力してください
df <- data.frame(
  x = c(),
  y = c()
)

ggplot(df, aes(x = x, y = y)) +
  geom_point(size = 2) +
  geom_line() +
  scale_x_continuous(name = "Theoretical quantiles", limits = c(-3, 3)) +
  scale_y_continuous(name = "Sample quantiles", limits = c(-3, 3)) +
  labs(title = "Q-Q Plot") +
  theme_bw(base_size = 14) +
  theme(plot.title = element_text(face = "bold", hjust = 0.5))