| np.pairs | R Documentation |
Compute pairwise nonparametric regressions and densities for a set of variables, then plot a pairs-style display with fitted smoothers.
np.pairs(y_vars, y_dat, ...)
np.pairs.plot(pair_list)
These arguments identify the variables, data, and pair specifications to plot.
pair_list |
list returned by |
y_dat |
data frame containing the variables listed in |
y_vars |
character vector of column names in |
Further graphical arguments are passed through to plotting methods.
... |
additional arguments passed to |
Documentation guide: see np.kernels for kernels, np.options for global options, and plot for plotting options.
On the diagonal, npudens is used to compute kernel density
estimates. Off-diagonal panels use npreg with residuals to draw
scatterplots and smoothers.
np.pairs returns a list with components
y_vars, pair_names, and pair_kerns.
np.pairs.plot returns NULL (invisibly).
np.kernels, np.options, plotnpudens, npreg
## Not run:
data("USArrests")
y_vars <- c("Murder", "UrbanPop")
names(y_vars) <- c("Murder Arrests per 100K", "Pop. Percent Urban")
pair_list <- np.pairs(
y_vars = y_vars,
y_dat = USArrests,
ckertype = "epanechnikov",
bwscaling = TRUE
)
np.pairs.plot(pair_list)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.