Unlimited learning, half price | 50% off

Last chance! 50% off unlimited learning

Sale ends in


cocoreg (version 0.1.1)

pathify: Create a path

Description

Given a set of numbers and a starting point, create a path from the starting point through each point. If cyclic = FALSE, the path stops at p[length(p)] and if cyclic = TRUE the patch goes back to ind.

Usage

pathify(ind, p, cyclic = FALSE)

Arguments

ind
[1,1] int, The starting point.
p
[1,m] int, A set of numbers through which the path must go, excluding the starting point.
cyclic
boolean, If TRUE, the path leads back to the starting point. If FALSE, the path stops at last element of p.

Value

A list containing the path definition.