makeNetwork: Generate network based on coordinates.

View source: R/makeNetwork.R

makeNetworkR Documentation

Generate network based on coordinates.

Description

Create a (clustered) network object.

Usage

makeNetwork(
  coordinates,
  distance.matrix = NULL,
  name = NULL,
  comment = NULL,
  membership = NULL,
  edge.weight.type = NULL,
  depot.coordinates = NULL,
  lower = NULL,
  upper = NULL,
  opt.tour.length = NULL,
  opt.tour = NULL,
  node.weights = NULL
)

Arguments

coordinates

[matrix]
Numeric matrix of 2D coordinates.

distance.matrix

[matrix]
Optional distance matrix.

name

[character(1) | NULL]
Optional name of the network.

comment

[character | NULL]
Optional additional comments on instance.

membership

[numeric | NULL]
Optional vector of memberships for clustered networks.

edge.weight.type

[character(1) | NULL] The edge weight type indicates how edge weights are represented in the TSPlib format. If distance.matrix is NULL, the passed value is ignored and EUC_2D is assigned. Otherwise the edge weight type must be one of the following {EUC_2D, EUC_3D, MAX_2D, MAX_3D, MAN_2D, MAN_3D, CEIL_2D, GEO, ATT, EXPLICIT}.

depot.coordinates

[matrix | NULL]
Numeric matrix of 2D coordinates of depots. Default is NULL, which means no depots at all.

lower

[numeric(1)]
Lower box constraint of cube.

upper

[numeric(1)]
Upper box constraint of cube.

opt.tour.length

[numeric(1)]
Optional length of the optimal roundtrip tour. Default is NULL, which means the tour length is unknown.

opt.tour

[integer]
Optional optimal permutation of node indizes. Default is NULL, which means the optimal tour is unknown.

node.weights

[numeric]
Vector of node weights (for weighted version of TSP). Default is NULL, i.e., no node weights at all.

Value

[Network]


jakobbossek/netgen documentation built on Feb. 11, 2024, 1:02 a.m.