dot2HPD: Process a .dot Graph File into a Hive Plot Data Object

Description Usage Arguments Details Value Author(s) See Also

View source: R/dot2HPD.R

Description

This function will read a .dot file containing a graph specification in the DOT language, and (optionally) using two other files, convert the information into a HivePlotData object.

Usage

1
2
dot2HPD(file = NULL, node.inst = NULL, edge.inst = NULL,
  axis.cols = NULL, type = "2D", desc = NULL, ...)

Arguments

file

The path to the .dot file to be processed.

node.inst

The path to a .csv file containing instructions about how to map node tags in the .dot file to parameters in the HivePlotData object. May be NULL.

edge.inst

The path to a .csv file containing instructions about how to map edge tags in the .dot file to parameters in the HivePlotData object. May be NULL.

axis.cols

A character vector giving the colors desired for the axes.

type

One of c("2D", "3D"). If 2D, a HivePlotData object suitable for use with plotHive will be created and the eventual hive plot will be static and 2D. If 3D, the HivePlotData object will be suitable for a 3D interactive plot using plot3dHive.

desc

Character. A description of the data set.

...

Other parameters to be passed downstream.

Details

This function is currently agnostic with respect to whether or not the .dot graph is directed or not. Either type will be processed, but if the graph is directed, this will only be indirectly stored in the HivePlotData object (in that the first node of an edge in the .dot file will be in HPD$nodes$id1 and the second node of an edge will be in HPD$nodes$id2. This fact can be used; see the vignette and mineHPD. Keep in mind the .dot standard is fairly loose. This function has been tested to work with several .dot files, include those with multiple tag=value attributes (in such cases, a typical line in the dot file should be formatted like this: node_name [tag1 = value1, tag2 = value2];). If you have trouble, please file a issue at Github so I can track it down.

Value

A HivePlotData object.

Author(s)

Bryan A. Hanson, DePauw University. [email protected]

See Also

See the vignette for an example of using this function. Use browseVignettes("HiveR") to produce the vignette.

adj2HPD for a means of importing adjacency matrices.


HiveR documentation built on July 28, 2017, 9:01 a.m.