\begin{Schunk}
\begin{Sinput}
 ## Creating a name vector for the depre items 
 varName_depre_i <- c("depre1_i","depre2_i", "depre3_i", "depre4_i", "depre5_i", "depre6_i")
 ## Requesting summary information for the Depression items
 summary(hbsc[ , varName_depre_i])
\end{Sinput}
\begin{Soutput}
    depre1_i        depre2_i        depre3_i        depre4_i        depre5_i        depre6_i    
 Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
 1st Qu.:1.000   1st Qu.:2.000   1st Qu.:1.000   1st Qu.:1.000   1st Qu.:1.000   1st Qu.:1.000  
 Median :2.000   Median :3.000   Median :1.000   Median :2.000   Median :2.000   Median :2.000  
 Mean   :2.332   Mean   :2.684   Mean   :1.817   Mean   :2.209   Mean   :2.485   Mean   :2.473  
 3rd Qu.:3.000   3rd Qu.:3.000   3rd Qu.:3.000   3rd Qu.:3.000   3rd Qu.:4.000   3rd Qu.:3.000  
 Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000  
 NA's   :78      NA's   :87      NA's   :96      NA's   :113     NA's   :117     NA's   :95     
\end{Soutput}
\begin{Sinput}
 ## Creating a demonstration data set (depre_i_miss) with increased missings
 depre_i <- (hbsc[ , varName_depre_i])
 depre_i_miss <- as.data.frame(lapply(depre_i, function(cc) cc[ sample(c(TRUE, NA), prob = c(0.90, 0.10), size = length(cc), replace = TRUE) ]))
 summary(depre_i_miss)
\end{Sinput}
\begin{Soutput}
    depre1_i        depre2_i        depre3_i        depre4_i        depre5_i        depre6_i    
 Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
 1st Qu.:1.000   1st Qu.:2.000   1st Qu.:1.000   1st Qu.:1.000   1st Qu.:1.000   1st Qu.:1.000  
 Median :2.000   Median :3.000   Median :1.000   Median :2.000   Median :2.000   Median :2.000  
 Mean   :2.331   Mean   :2.678   Mean   :1.826   Mean   :2.204   Mean   :2.484   Mean   :2.475  
 3rd Qu.:3.000   3rd Qu.:3.000   3rd Qu.:3.000   3rd Qu.:3.000   3rd Qu.:4.000   3rd Qu.:3.000  
 Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000  
 NA's   :483     NA's   :482     NA's   :512     NA's   :524     NA's   :519     NA's   :503    
\end{Soutput}
\end{Schunk}
