ggAncova: Make an interactive plot for an ANCOVA model

Description Usage Arguments Methods (by class) Examples

View source: R/ggAncova.R

Description

Make an interactive plot for an ANCOVA model

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
ggAncova(x, ...)

## Default S3 method:
ggAncova(x, mapping, use.label = TRUE, use.labels = TRUE, ...)

## S3 method for class 'formula'
ggAncova(x, data, ...)

## S3 method for class 'lm'
ggAncova(x, label = NULL, digits = 1, interactive = FALSE, ...)

Arguments

x

an object

...

additional arguments passed to the generic function

mapping

Set of aesthetic mappings created by aes or aes_.

use.label

Logical. Whether or not use column label in case of labelled data

use.labels

Logical. Whether or not use value labels in case of labelled data

data

a data.frame

label

A character string of column name be assigned to the label

digits

An integer indicating the number of decimal places

interactive

A logical value. If TRUE, an interactive plot will be returned

Methods (by class)

Examples

1
2
3
4
5
6
7
require(moonBook)
require(ggplot2)
require(ggiraph)
ggAncova(radial,aes(age,NTAV,color=sex),interactive=TRUE)
fit=lm(NTAV~age+HBP,data=radial)
ggAncova(fit,interactive=TRUE)
ggAncova(NTAV~age+DM,data=radial)

Example output

Loading required package: moonBook

Attaching package: 'moonBook'

The following objects are masked from 'package:ggiraphExtra':

    addLabelDf, getMapping

Loading required package: ggplot2
Loading required package: ggiraph

ggiraphExtra documentation built on Oct. 23, 2020, 7:39 p.m.