Rdocumentation
powered by
Learn R Programming
tspmeta (version 1.2)
tsp_instance: Generates a TSP instance S3 object either from city coordinates.
Description
Generates a TSP instance S3 object either from city coordinates.
Usage
tsp_instance(coords, dists)
Arguments
coords
[
matrix
] Numeric matrix of city coordinates, rows denote cities.
dists
[
dist
] Optional distance matrix containing the inter-city distances. If not provided, the (euclidean) distances are computed from the coordinates.
Value
[
tsp_instance
].