Description Usage Arguments Value Examples
View source: R/rescaleNetwork.R
Normalize network coordinates to the unit cube while maintaining its geography.
1  | rescaleNetwork(x, method = "global2")
 | 
x | 
 [  | 
method | 
 [ 
 Default is   | 
[Network]
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18  | ## Not run: 
library(gridExtra)
x = generateClusteredNetwork(n.points = 100L, n.cluster = 4L, name = "Rescaling Demo")
# here we "stretch" the instance x direction to visualize the differences of
# the rescaling mehtods
x$coordinates[, 1] = x$coordinates[, 1] * 10L
x$upper = x$upper * 10L
pls = list(
  autoplot(x) + ggtitle("Original"),
  autoplot(rescaleNetwork(x, method = "by.dimension")) + ggtitle("By dimension"),
  autoplot(rescaleNetwork(x, method = "global")) + ggtitle("Global"),
  autoplot(rescaleNetwork(x, method = "global2")) + ggtitle("Global2")
)
pls$nrow = 1L
do.call(grid.arrange, pls)
## End(Not run)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.