箱ひげ図(群間比較)

箱ひげ図テンプレート。複数群のデータ分布を比較。中央値・四分位・外れ値を表示。

箱ひげ図分布比較中央値四分位
箱ひげ図(群間比較)

R Code (ggplot2)

library(ggplot2)

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

ggplot(df, aes(x = x, y = y)) +
  geom_point(size = 2) +
  geom_line() +
  scale_x_continuous(name = "Group", limits = c(0, 6)) +
  scale_y_continuous(name = "Value", limits = c(0, 100)) +
  labs(title = "Box Plot (Group Comparison)") +
  theme_bw(base_size = 14) +
  theme(plot.title = element_text(face = "bold", hjust = 0.5))