make.grid: Optimize rectangular grid plots

Description Usage Arguments Value Author(s) Examples

View source: R/metaseqr.util.R

Description

Returns a vector for an optimized m x m plot grid to be used with e.g. par(mfrow). m x m is as close as possible to the input n. Of course, there will be empty grid positions if n < m x m.

Usage

1

Arguments

n

An integer, denoting the total number of plots to be created.

Value

A 2-element vector with the dimensions of the grid.

Author(s)

Panagiotis Moulos

Examples

1
2
g1 <- make.grid(16) # Returns c(4,4)
g2 <- make.grid(11) # Returns c(4,3)

pmoulos/metaseqR documentation built on Dec. 21, 2020, 6:19 a.m.