Learn R Programming

netgen (version 1.3.2)

exportToTSPlibFormat: Exports a network to the TSPlib format.

Description

Exports a network to the TSPlib format.

Usage

exportToTSPlibFormat(x, filename, name = NULL, comment = NULL,
  use.extended.format = TRUE, full.matrix = FALSE, digits = 10L)

Arguments

x

[Network] Network to export.

filename

[character(1)] File name.

name

[character(1) | NULL] Character string describing the instance. Used for the NAME field in the TSPlib file format. Otherwise, the name of the instance is used. If the latter is NULL, this parameter is mandatory.

comment

[character(1) | NULL] Optional string with additional information about the instance. Used for the COMMENT field. If not provided the comment field of the instance is used. If the latter is NULL, no comment at all is saved.

use.extended.format

[logical(1)] Use the “extended tsplib format” with additional information like cluster membership and bounds? Default is TRUE.

full.matrix

[logical(1)] Make use of “FULL\_MATRIX” “EDGE\_WEIGHT\_FORMAT” instead of node coordinates? Default is FALSE.

digits

[integer(1)] Round coordinates to this number of digits. Default is 10.

Value

Nothing