Hi, Can someone explain why it says the cases are complete. It seems they
are not.

head(x)
  rnum    Exam.Title Patient.ID  Age Sex Impression2
1    1 Temporal bone    3529243 009Y   M
2    2 Temporal bone    3529243 010Y   M
3    3          Head    3508570 002M   M
4    4        Sacrum    3494713 004D   F
5    5          Head    3471128 015M   F
6    6          Head    3494480 022M   M
  Impression3 AgeByYear Exposure      Reason   Result
1                     9        H
2                    10        H
3                     0        H   premature Negative
4                     0        P
5                     1        H     seizure negative
6                     1        H head trauma Negative
  Repeat Result.1
1      h        P
2     r1        P
3               N
4               P
5               N
6      h        N
> complete.cases(x[1:5,])
[1] TRUE TRUE TRUE TRUE TRUE
> class(x)
[1] "data.frame"
> str(x)
'data.frame': 978 obs. of  13 variables:
 $ rnum       : int  1 2 3 4 5 6 7 8 9 10 ...
 $ Exam.Title : Factor w/ 75 levels "Abdomen","Abdomen (Post CE)",..: 74 74
21 68 21 21 21 21 2 3 ...
 $ Patient.ID : int  3529243 3529243 3508570 3494713 3471128 3494480
3494480 3553704 3295006 3295006 ...
 $ Age        : Factor w/ 53 levels "000Y","001D",..: 30 33 4 11 43 51 51
40 33 33 ...
 $ Sex        : Factor w/ 2 levels "F","M": 2 2 2 1 1 2 2 2 1 1 ...
 $ Impression2: Factor w/ 114 levels "","????","?????",..: 1 1 1 1 1 1 1 1
1 57 ...
 $ Impression3: Factor w/ 22 levels "","??","??????",..: 1 1 1 1 1 1 1 1 1
13 ...
 $ AgeByYear  : int  9 10 0 0 1 1 1 13 10 10 ...
 $ Exposure   : Factor w/ 27 levels "A","A 2","A P",..: 11 11 11 27 11 11
11 11 1 2 ...
 $ Reason     : Factor w/ 112 levels "","abnormal behavior, check",..: 1 1
80 1 87 36 36 36 1 1 ...
 $ Result     : Factor w/ 7 levels "","Inconclusive",..: 1 1 4 1 3 4 4 4 1
1 ...
 $ Repeat     : Factor w/ 13 levels "","h","r1","r10",..: 2 3 1 1 1 2 3 1 2
6 ...
 $ Result.1   : Factor w/ 2 levels "N","P": 2 2 1 2 1 1 1 1 2 2 ...
> mode(x)
[1] "list"

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to