Learn R Programming

intsvy (version 2.9)

plot.intsvy.reg: Graphical representation of regression models in groups

Description

Functions pisa.reg, pisa.reg.pv, piaac.reg and piaac.reg.pv produce object of the class intsvy.reg. The function plot.intsvy.reg presents this list of regression models graphically.

Usage

# S3 method for intsvy.reg
plot(x, ..., vars, se = TRUE, sort = FALSE)

Value

Returns object of ggplot class with barplot. As with other ggplot objects the plus sign "+" can be used outside this function to modify graph parameters of the returning ggplot object. Works for one way, two-way and three-way contingency tables.

Arguments

x

An object of the class intsvy.reg returned by pisa.reg, pisa.reg.pv, piaac.reg and piaac.reg.pv functions.

...

Other arguments

vars

Variable labels of coefficients to be plotted. If none selected all coefficients are plotted including the R-squared

se

If TRUE add whiskers for standard errors.

sort

If TRUE groups are sorted in alphabetical order.

See Also

plot.intsvy.table, plot.intsvy.mean

Examples

Run this code
if (FALSE) {
# Independent variables
x.vars <- c("ESCS", "COGACT", "TCHBEHTD", "TCHBEHSO")
# Model estimation
my.mod <- pisa.reg.pv(pvlabel="MATH", x=x.vars, by="IDCNTRYL", data=pisa12)
# Plot
plot(gen.mod, vars = c("COGACT", "TCHBEHTD", "TCHBEHSO"), sort=TRUE)
}

Run the code above in your browser using DataLab