coordCMap {cogmapr} | R Documentation |
Coordinates of the vertices of a Cognitive Map
Description
Get the coordinates of the vertices of a Cognitive Map. The output of this function can be useful for plotting Cognitive Maps in a personalize ways (as with ggplot2 as done by the ggCMap function of this package)
Usage
coordCMap(soc.cmap, layoutType = "neato")
Arguments
soc.cmap |
An object of class SocCMap, as an output of the SocCMap function |
layoutType |
Type of graph. See detail in RGraphViz. Can be 'neato', 'dot', 'twopi', 'circo', and 'fdp'. The default is 'neato'. |
Value
A data frame with three variable :
- $vertex
The number of the vertex)
- $x
The x coordinate of the vertex
- $y
The y coordinate of the vertex
Examples
project_name <- "a_new_project"
main_path <- paste0(system.file("testdata", package = "cogmapr"), '/')
my.project <- ProjectCMap(main_path, project_name)
edg.scm <- EdgSocCMap(my.project, min.weight=6, weighted.icm=TRUE)
scm <- SocCMap(edg.scm, my.project, label = "name", shape = "plaintext")
coordCMap(scm)
[Package cogmapr version 0.9.3 Index]