[R-sig-eco] as.ltraj-adehabitatLT

Michael Sumner mdsumner at gmail.com
Mon Aug 8 01:45:23 CEST 2011


The error message says it all - there are duplicated date/times in the
"da" input for a given id. You should investigate these and either
edit or remove them so that the trajectory makes sense.

Something like this can show which ids/datetimes are duplicated, but
without having your data it's just a guess (and untested):
lapply(split(data.frame(da, data.sini$Name), data.sini$Name),
function(x) x[is.duplicated(x),])



On Mon, Aug 8, 2011 at 6:58 AM, Natasa Djakovic <natasa.djakovic at umb.no> wrote:
> Hi,
>
> I'm trying to create an object of class ltray to store animal movements, but keep getting an error message: "Error in as.ltraj(xy = data.sini[, c("X", "Y")], date = da, id = data.sini$Name) : non unique dates for a given burst."
>
> Does anyone have a suggestion how to solve this problem?
>
> Kind regards,
> Natasa
>
> _______________________________________________
> R-sig-ecology mailing list
> R-sig-ecology at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
>



-- 
Michael Sumner
Institute for Marine and Antarctic Studies, University of Tasmania
Hobart, Australia
e-mail: mdsumner at gmail.com



More information about the R-sig-ecology mailing list