value_hierarchy_tree: Value Hierarchy Tree

Description Usage Arguments Value Examples

View source: R/value_hierarchy_tree.R

Description

: Plots a value hierarchy tree

Usage

1
2
3
4
value_hierarchy_tree(..., leaves, weights, nodestyle = "filled, rounded",
  nodeshape = "box", nodefillcolor = "white", nodefontname = "helvetica",
  nodefontcolor = "black", leavesshape = "egg", leavesfillcolor = "gray",
  leavesfontcolor = "black", leavesfontname = "helvetica")

Arguments

...

One or more character vectors containing a single level of nodes. The character vector containing the end nodes should not be entered here. If there isn't a node for a level of the branch, it should be entered as ""

leaves

Character vector of values containing the last node of the branches

weights

Character or numeric vector of weights associated with the end node of the branches (Optional)

nodestyle

Style of the nodes, default is filled, rounded

nodeshape

Shape of the nodes, default is box

nodefillcolor

Fill color of the nodes, default is white

nodefontname

Font of the nodes, default is helvetica

nodefontcolor

Font color of the nodes, default is black

leavesshape

Shape of the leaves, default is egg

leavesfillcolor

Fill color of the leaves, default is gray

leavesfontcolor

Font color of the leaves, default is black

leavesfontname

Font of the leaves, default is helvetica

Value

Value hierarchy tree plot

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run:  branches<- as.data.frame(matrix(ncol=5,nrow=7))
names(branches)<-c("Level1","Level2","Level3","leaves","weights")
branches[1,]<-rbind("QB","Elusiveness","Speed","Forty","0.092")
branches[2,]<-rbind("QB","Elusiveness","Agility","Shuttle","0.138")
branches[3,]<-rbind("QB","Size","","Height","0.096")
branches[4,]<-rbind("QB","Size","","Weight","0.224")
branches[5,]<-rbind("QB","Intelligence","","Wonderlic","0.07")
branches[6,]<-rbind("QB","Strength","Explosiveness","Vertical","0.152")
branches[7,]<-rbind("QB","Strength","Power","Broad","0.228")

value_hierarchy_tree(branches$Level1,branches$Level2,branches$Level3,
leaves=branches$leaves,weights=branches$weights)

## End(Not run)

AFIT-R/DecisionAnalysis documentation built on July 31, 2018, 12:10 a.m.