Learn R Programming

bigstatsr (version 1.6.1)

plot.mhtest: Plot method

Description

Plot method for class mhtest.

Usage

# S3 method for mhtest
plot(x, type = c("hist", "Manhattan", "Q-Q", "Volcano"), coeff = 1, ...)

Value

A ggplot2 object. You can plot it using the print method. You can modify it as you wish by adding layers. You might want to read this chapter

to get more familiar with the package ggplot2.

Arguments

x

An object of class mhtest.

type

Either.

  • "hist": histogram of p-values (the default).

  • "Manhattan": plot of the negative logarithm (in base 10) of p-values.

  • "Q-Q": Q-Q plot.

  • "Volcaco": plot of the negative logarithm of p-values against the estimation of coefficients (e.g. betas in linear regression)

coeff

Relative size of text. Default is 1.

...

Not used.

See Also

big_univLinReg, big_univLogReg, plot.big_SVD and asPlotlyText.

Examples

Run this code
set.seed(1)

X <- big_attachExtdata()
y <- rnorm(nrow(X))
test <- big_univLinReg(X, y)

plot(test)
plot(test, type = "Volcano")
plot(test, type = "Q-Q")
plot(test, type = "Manhattan")
plot(test, type = "Manhattan") + ggplot2::ggtitle(NULL)

Run the code above in your browser using DataLab