# NOT RUN {
# Trio
x = ped(id = 1:3, fid = c(0,0,1), mid = c(0,0,2), sex = c(1,2,1))
# Female singleton
y = singleton('NN', sex = 2)
# Selfing
z = ped(id = 1:2, fid = 0:1, mid = 0:1, sex = 0:1)
stopifnot(hasSelfing(z))
# Disconnected pedigree: Trio + singleton
w = ped(id = 1:4, fid = c(2,0,0,0), mid = c(3,0,0,0), sex = c(1,1,2,1))
stopifnot(is.pedList(w), length(w) == 2)
# }
Run the code above in your browser using DataLab