autoplot.apd_pca: Plot the distribution function for pcas

Description Usage Arguments Value Examples

View source: R/plot.R

Description

Plot the distribution function for pcas

Usage

1
2
## S3 method for class 'apd_pca'
autoplot(object, ...)

Arguments

object

An object produced by apd_pca.

...

An optional set of dplyr selectors, such as dplyr::matches() or dplyr::starts_with() for selecting which variables should be shown in the plot.

Value

A ggplot object that shows the distribution function for each principal component.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
library(ggplot2)
library(dplyr)
data(biomass, package = "recipes")

biomass_ad <- apd_pca(biomass[, 3:7])

autoplot(biomass_ad)
# Using selectors in `...`
autoplot(biomass_ad, distance) + scale_x_log10()
autoplot(biomass_ad, matches("PC[1-2]"))

tidymodels/applicable documentation built on Nov. 5, 2019, 10:08 a.m.