Learn R Programming

RSA (version 0.5.1)

getPar: Retrieves several variables from an RSA object

Description

Retrieves several variables from an RSA object

Usage

getPar(x, type = "syntax", model = "full", ...)

Arguments

x
RSA object
type
One of: "syntax", "coef", "R2"
model
A string specifying the model; defaults to "full"
...
Additional parameters passed to the extraction function

Details

None so far.

See Also

RSA

Examples

Run this code
set.seed(0xBEEF)
n <- 300
err <- 2
x <- rnorm(n, 0, 5)
y <- rnorm(n, 0, 5)
df <- data.frame(x, y)
df <- within(df, {
	diff <- x-y
	absdiff <- abs(x-y)
	sqdiff <- (x-y)^2
	z.sq <- sqdiff + rnorm(n, 0, err)
})

r1 <- RSA(z.sq~x*y, df)
getPar(r1, "syntax")
getPar(r1, "R2")
getPar(r1, "coef")

Run the code above in your browser using DataLab