Learn R Programming

psre (version 0.1.2)

lsa: Linear Scatterplot Array

Description

Produces a linear scatterplot array with marginal histograms

Usage

lsa(
  formula,
  xlabels = NULL,
  ylab = NULL,
  data,
  ptsize = 1,
  ptshape = 1,
  ptcol = "gray65"
)

Value

A cowplot object.

Arguments

formula

Formula giving the variables to be plotted.

xlabels

Vector of character strings giving the labs of variables to be used in place of the variable names.

ylab

Character string giving y-variable label to be used instead of variable name.

data

A data frame that holds the variables to be plotted.

ptsize

Size of points.

ptshape

Shape of points.

ptcol

Color of points.

Examples

Run this code
data(wvs)
lsa(formula = as.formula(sacsecval ~ resemaval + moral + 
                           pct_univ_degree + pct_female + 
                           pct_low_income), 
  xlabels = c("Emancipative Vals", "Moral Perm", 
              "% Univ Degree", "% Female", "% Low Income"), 
  ylab = "Secular Values", 
  data=wvs)

Run the code above in your browser using DataLab