You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: R/frames_graph.R
+6-2
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,9 @@
16
16
#' @details To later on side-by-side join spatial frames created using \code{\link{frames_spatial}} with frames created with \code{\link{frames_graph}} for animation,
17
17
#' equal inputs must have been used for both function calls for each of the arguments \code{m}, \code{r_list}, \code{r_times} and \code{fade_raster}.
18
18
#'
19
+
#' If argument \code{path_colours} is not defined (set to \code{NA}), path colours can be defined by adding a character column named \code{colour} to \code{m}, containing a colour code or name per row (e.g. \code{"red"}. This way, for example, column \code{colour} for all rows belonging to individual A can be set to \code{"green"}, while column \code{colour} for all rows belonging to individual B can be set to \code{"red"}.
20
+
#' Colours could also be arranged to change through time or by behavioral segments, geographic locations, age, environmental or health parameters etc. If a column name \code{colour} in \code{m} is missing, colours will be selected automatically. Call \code{colours()} to see all available colours in R.
21
+
#'
19
22
#' @return An object of class \code{moveVis}. If \code{return_data} is \code{TRUE}, a \code{data.frame} is returned (see \code{return_data}).
if(!is.logical(fade_raster)) out("Argument 'fade_raster' has to be either TRUE or FALSE.", type=3)
94
97
95
98
if(!is.numeric(path_size)) out("Argument 'path_size' must be of type 'numeric'.", type=3)
99
+
if(is.character(path_colours)) if(length(path_colours) != n.indiv(m)) out("Argument 'path_colours' must be of same length as the number of individual tracks of 'm', if defined. Alternatively, use a column 'colour' for individual colouring per coordinate within 'm' (see details of ?frames_spatial).", type=3)
96
100
if(!is.logical(path_legend)) out("Argument 'path_legend' must be of type 'logical'.", type=3)
97
101
if(!is.character(path_legend_title)) out("Argument 'path_legend_title' must be of type 'character'.", type=3)
98
102
if(!is.logical(return_data)) out("Argument 'return_data' must be of type 'logical'.", type=3)
0 commit comments