Importing regular txt

26 views
Skip to first unread message

vmont...@gmail.com

unread,
Feb 17, 2020, 1:31:00 AM2/17/20
to ctmm R user group
Hi is there some steps to import data for dummies???, I went throughout all the tutorial paper and everything run pretty well , but when I did tried to import real data from my study using the function “as telemetry” for a basic txt data frame it said a huge error for eve thing .... can someone help me out

Ross Couvillon

unread,
Feb 17, 2020, 4:38:00 PM2/17/20
to ctmm R user group
My code for importing data is provided below. Make sure you upload your data through www.movebank.org as this will format it in a way that CTMM can read. Once entered, download data as a .csv file. 

#Set working directory
setwd("C:/location on your computer where your .csv file is")       #Use / and not \ to separate 

#Import, coerce, and summarize MoveBank data
dataset<-as.telemetry("yourdataset.csv")

#Specify specific individual
individual1 <- dataset$individual1


Ross

Christen Fleming

unread,
Feb 17, 2020, 9:04:35 PM2/17/20
to ctmm R user group
Hi,

I would try to first import the text file with read.csv() and make sure that its importing correctly into a data.frame object with the right columns. You can then run as.telemetry() on the data.frame object.

But, as Ross suggested, getting your data through MoveBank is much preferred for making sure everything is setup correctly.

Best,
Chris
Reply all
Reply to author
Forward
0 new messages