latent: Set specifications of a latent variable

Description Usage Arguments Details Value Author(s) See Also Examples

Description

Use this function to specify the graphic characteristics of a latent variable. The specifications will be used by the function draw to plot latent variables (in a path diagram).

Usage

1
2
3
4
  latent(label = "latent", x = 0.5, y = 0.5, rx = 0.05,
    ry = 0.05, border = "white", lwd = 2, fill = "#5f8bd7",
    col = "white", cex = 1, vfont = NULL, font = 2,
    family = "sans")

Arguments

label

A character string with the label to be displayed.

x

x-axis coordinate for center of ellipse.

y

y-axis coordinate for center of ellipse.

rx

long radius of ellipse.

ry

short radius of ellipse.

border

color of the border.

lwd

width of border line.

fill

color to fill the ellipse

col

color of the label.

cex

numeric character expansion of the label.

vfont

font family of the label.

font

An integer specifying which font to use for the label. See par

family

The name of a font family for drawing text. Standard values are "serif", "sans" and "mono".

Details

Latent variables are drawn as ellipses using the function plotellipse

Value

An object of class "latent", which is a list with the specified parameters to draw latent variables.

Author(s)

Gaston Sanchez

See Also

manifest, draw

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
## Not run: 
 # latent variables
 attack = latent("ATTACK", x=0.35, y=0.7, rx=0.08, ry=0.06)
 defense = latent("DEFENSE", x=0.35, y=0.3, rx=0.08, ry=0.06)
 success = latent("SUCCESS", x=0.65, y=0.5, rx=0.08, ry=0.06)

 # opwn wall
 wall()
 title("Drawing three latent variables", col.main="gray20")

 # draw variables
 draw(attack)
 draw(defense)
 draw(success)
 
## End(Not run)

gastonstat/pathdiagram documentation built on May 16, 2019, 5:46 p.m.