Random routes using map

Hello folks,

I want to use random route instructions on city maps. For example, the statement "left, right, left, right, ...." should be simulated at every possible starting point.
If necessary, the selection probabilities of the households should then be calculated.
Do yall know of any packages that could help?

Thanks!

We probably need more information but if all you need is a vector of left and right then this should do:

sample(c("left", "right"), 100,  replace = TRUE)

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.