<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi Richard,<br>
<br>
Thanks for your good questions, see replies below:<br>
<br>
<div class="moz-cite-prefix">On 10/13/2014 11:55 AM,
<a class="moz-txt-link-abbreviated" href="mailto:richard.baxter@ieu.uzh.ch">richard.baxter@ieu.uzh.ch</a> wrote:<br>
</div>
<blockquote
cite="mid:OF6BF1EEF4.1FAFE4F3-ONC1257D70.0066B273-C1257D70.0067EB00@lotus.uzh.ch"
type="cite"><font face="Default Sans
Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><font
size="2"><font face="Verdana, Arial, Helvetica, sans-serif">Dear
T-Locoh list,</font>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><br>
</div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;">Really enjoying using this package at the
moment, however, I have some methodological questions:</div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><br>
</div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;">1) First up is, was there any resolution to the
thread '<span style="white-space: pre-wrap; font-family:
arial, helvetica, sans-serif;">showing duration of visit
and visitation rate' </span><span style="white-space:
pre-wrap; font-family: arial, helvetica, sans-serif;
font-size: 13px;">15 Jul 2014</span><span
style="font-family: arial, helvetica, sans-serif;
white-space: pre-wrap;"> ? As visualizing </span></div>
</font><font size="2">
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;">movement data,
UDs or movement paths, is essential for communication. </span></div>
</font></font></blockquote>
<br>
I don't remember if we finished that discussion, but let me look
back at that thread and get back to you. <br>
<br>
<blockquote
cite="mid:OF6BF1EEF4.1FAFE4F3-ONC1257D70.0066B273-C1257D70.0067EB00@lotus.uzh.ch"
type="cite"><font face="Default Sans
Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><font
size="2">
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;">2) Related to
the first, but hopefully much simpler: </span></div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;"><span
class="Apple-tab-span" style="white-space:pre"> </span>I'm
a fan of the trajectory plots with the differing colours
for different times but i was wondering how this could be
refined</span></div>
<div><span class="Apple-tab-span" style="font-family: arial,
helvetica, sans-serif; white-space: pre;"> </span><span
style="white-space: pre-wrap;">to show the movement from
start to end...as in, green at the start of the movement
path (or first timepoint), red at the last time point with
a graduated colour palette in between the points.</span></div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;"><span
class="Apple-tab-span" style="white-space:pre"> </span>It's
possible to do in other packages but working with T-Locoh
is much more intuitive for me except for the plotting.</span></div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;"><span
class="Apple-tab-span" style="white-space:pre"> </span>Is
this possible? This would be awesome for migratory
animals. </span></div>
</font></font></blockquote>
<br>
Yes you can change the colors that are used to display locations
when plotting a locoh-xy object. From the help file for
plot.locoh.lxy: <br>
<br>
<tt>col: A single value or vector of color values. Can also be
'auto' (default) in which case the colors saved in the locoh-xy
object will be used (which are rainbow by default).</tt><tt><br>
</tt><br>
If you wanted all the locations to be the same color, you could pass
a single color value as col. For example:<br>
<br>
<big><tt>plot(toni.lxy, col="darkblue")</tt></big><br>
<br>
To use a custom color ramp, you can create a vector of color values
(same length as the number of points) and pass that as col. To
display the locations green to red, for example, you could run:<br>
<tt><br>
</tt><big><tt>n <- nrow(toni.lxy$pts)<br>
green.to.red <- colorRampPalette(c("#00FF00","#FF0000"))(n)<br>
plot(toni.lxy, col=green.to.red)</tt><tt><br>
</tt></big><br>
Granted that the plotting functions in tlocoh have a lot of options
that can make them klunky to use. Note however you can easily grab
the SpatialPointsDataFrame of a locoh-xy object, which is saved in
the <big><tt>pts</tt></big> element: <br>
<br>
x <- toni.lxy$pts<br>
summary(x)<br>
<br>
<br>
<blockquote
cite="mid:OF6BF1EEF4.1FAFE4F3-ONC1257D70.0066B273-C1257D70.0067EB00@lotus.uzh.ch"
type="cite"><font face="Default Sans
Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><font
size="2">
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;">3) related to
plotting: I'm plotting data for between 31 individuals so
when I plot the lxy, the command returns the plots in grid
form or a lattice.</span></div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;"><span
class="Apple-tab-span" style="white-space:pre"> </span>Is
it possible to separate the plots for the into individuals
plot windows? </span></div>
</font></font></blockquote>
<br>
Yes, set overlay=TRUE<br>
<br>
<blockquote
cite="mid:OF6BF1EEF4.1FAFE4F3-ONC1257D70.0066B273-C1257D70.0067EB00@lotus.uzh.ch"
type="cite"><font face="Default Sans
Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><font
size="2">
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;"><br>
</span></div>
<div style="font-family: Verdana, Arial, Helvetica,
sans-serif;"><span style="white-space: pre-wrap;
font-family: arial, helvetica, sans-serif;">4) Not sure
what is wrong with the data or my coding but when looking
at my sampling freq, there is also bursts below tau0.2
(See attached) similar to the T-LoCoh tutorial, but when i
run the code I get the following error:</span></div>
<div><span style="font-family: arial, helvetica, sans-serif;
white-space: pre-wrap;"><span class="Apple-tab-span"
style="white-space:pre"> </span></span><span
style="white-space: pre-wrap;">> mal.lxy <-
lxy.thin.bursts(mal.lxy, thresh=0.2)
No bursts were found for id MIDC_01 No bursts were found
for id MIDCST_02 New No bursts were found for id MIDIN_01
New No bursts were found for id MIDIN_02 No bursts were
found for id MLB_01 No bursts were found for id MLB_02
Error in lxy[["pts"]][-idx.remove, ] : error in evaluating
the argument 'i' in selecting a method for function '[':
Error in -idx.remove : invalid argument to unary operator</span></div>
<div><span style="white-space: pre-wrap;"><br>
</span></div>
<div><span style="white-space: pre-wrap;"><span
class="Apple-tab-span" style="white-space:pre"> </span>What
is wrong? </span></div>
</font></font></blockquote>
<br>
This sounds like a bug, or an untrapped error. Let me send you some
suggestions in a separate message.<br>
<br>
<blockquote
cite="mid:OF6BF1EEF4.1FAFE4F3-ONC1257D70.0066B273-C1257D70.0067EB00@lotus.uzh.ch"
type="cite"><font face="Default Sans
Serif,Verdana,Arial,Helvetica,sans-serif" size="2"><font
size="2">
<div><br>
</div>
<div><span style="white-space: pre-wrap;">Any help would be
most appreciated as I'm due to give a presentation about
this for our R-lunch course! </span></div>
<div><span style="white-space: pre-wrap;"><br>
</span></div>
<div><span style="white-space: pre-wrap;">Best,</span></div>
<div><span style="white-space: pre-wrap;">Rich</span></div>
</font>
</font>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Tlocoh-info mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Tlocoh-info@lists.r-forge.r-project.org">Tlocoh-info@lists.r-forge.r-project.org</a>
<a class="moz-txt-link-freetext" href="http://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/tlocoh-info">http://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/tlocoh-info</a>
</pre>
</blockquote>
<br>
</body>
</html>