as_flextable.pam: Transform a 'pam' object into a flextable

View source: R/as_flextable.R

as_flextable.pamR Documentation

Transform a 'pam' object into a flextable

Description

produce a flextable describing a pam object. The function is only using package 'broom' that provides the data presented in the resulting flextable.

Usage

## S3 method for class 'pam'
as_flextable(x, digits = 4, ...)

Arguments

x

a cluster::pam() object

digits

number of digits for the numeric columns

...

unused argument

See Also

Other as_flextable methods: as_flextable(), as_flextable.data.frame(), as_flextable.gam(), as_flextable.glm(), as_flextable.grouped_data(), as_flextable.htest(), as_flextable.kmeans(), as_flextable.lm(), as_flextable.merMod(), as_flextable.summarizor(), as_flextable.table(), as_flextable.tabular(), as_flextable.tabulator(), as_flextable.xtable()

Examples

if (require("cluster")) {
  dat <- as.data.frame(scale(mtcars[1:7]))
  cl <- pam(dat, 3)
  ft <- as_flextable(cl)
  ft
}

flextable documentation built on Oct. 30, 2024, 9:15 a.m.