2018-10-25
閱讀量:
1195
直方圖讓如何顯著性標(biāo)記
# loading needed libraries
library(ggstatsplot)
library(psych)
library(dplyr)
# looking at the structure of the data using glimpsedplyr
::glimpse(
x =psych
::sat.act)
#> Observations: 700
#> Variables: 6
#> $ gender??? <int> 2, 2, 2, 1, 1, 1, 2, 1, 2, 2, 1, 2, 1, 2, 2, 2, 2, 2...
#> $ education <int> 3, 3, 3, 4, 2, 5, 5, 3, 4, 5, 3, 4, 4, 4, 3, 4, 3, 4...
#> $ age?????? <int> 19, 23, 20, 27, 33, 26, 30, 19, 23, 40, 23, 34, 32, ...
#> $ ACT?????? <int> 24, 35, 21, 26, 31, 28, 36, 22, 22, 35, 32, 29, 21, ...
#> $ SATV????? <int> 500, 600, 480, 550, 600, 640, 610, 520, 400, 730, 76...
#> $ SATQ????? <int> 500, 500, 470, 520, 550, 640, 500, 560, 600, 800, 71...ggstatsplot
::gghistostats(
???
data =psych
::sat.act,?????????????????????????????
# data from which variable is to be taken???
x =ACT,???????????????????????????????????????????
# numeric variable???
results.subtitle =FALSE
,??????????????????????????
# don't run statistical tests???
messages =FALSE
,??????????????????????????????????
# turn off messages???
xlab ="ACT Score"
,????????????????????????????????
# x-axis label???
title ="Distribution of ACT Scores"
,??????????????
# title for the plot???
subtitle ="N = 700"
,??????????????????????????????
# subtitle for the plot???
caption ="Data courtesy of: SAPA project (https://sapa-project.org)"
,
# caption for the plot???
centrality.k =1
???????????????????????????????????
# show 1 decimal places for centrality label? )






評論(0)


暫無數(shù)據(jù)
CDA考試動(dòng)態(tài)
CDA報(bào)考指南
推薦帖子
0條評論
0條評論
0條評論