by jlaake » Tue Feb 22, 2011 6:31 pm
The posting by harding about the ellipsis is possible but dhewitt is correct that the "." is not for the MS models as they are currently coded. No reason though that "." couldn't be used to represent an uncertain state if the code knew to interpret that way. We do need to know what model you are using. They aren't all interchangeable. One quick way to find the problems is to use nchar to get the lengths of each of the capture histories.
Here is an example with dipper.
> data(dipper)
> nchar(dipper$ch)
[1] 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 ...
Now I'll mess up the second and 44th ch and show how to identify which have a length that doesn't match length of first capture history which is presumed to be correct here.
> dipper$ch[2]="000100"
> dipper$ch[44]="100100"
> dipper[nchar(dipper$ch)!=nchar(dipper$ch[1]),]
ch sex
2 000100 Female
44 100100 Female
If you know the length (say 7 in this case), you could use:
> dipper[nchar(dipper$ch)!=7,]
ch sex
2 000100 Female
44 100100 Female
I hope this helps you track down the problem. The solution harding provided would be fine for something like CJS or occupancy and the dot notation is simply a short-hand way of doing so. The solution of using 0 is not a particularly good one for MS state uncertainty. See paper by Conn and Cooch in Journal of Applied Ecology 2009.