I am evaluating the percentage of natural area in a gradient that goes from one to ten kilometers, in some areas of study. However some areas are not large enough and do not cover all distances, therefore, in some distances it generated NAs. For this reason, my data does not fit to perform repeated measures ANOVA, that the most indicated for dependent variables or longitudinal analysis. But researching the literature, I found that the Generalized estimating equations (GEE) can handle missing values, but to use GEE need to know if the missing values are missing completely at random (MCAR).
I am trying to do these analyzes on R, however I am not able to understand the codes that I found on the internet, and the packages that make these analyzes generally have already inspired.
Replicable data set
dfr <- data.frame( ID= rep(seq (1, 60, 1), 10),natural=rnorm(600), Dist=sample(1:10, 100,
replace=TRUE))
dfr <- dfr[order(dfr$Dist), ]
dfr$natural <- replace(dfr$natural, which(dfr$natural < 0), NA)
Aucun commentaire:
Enregistrer un commentaire