Skip to content

Add grid() args to tpar? #235

@grantmcdermott

Description

@grantmcdermott

At present, we support a simple logic argument for automatically drawing a grid all plots via tpar(grid = TRUE).

But this doesn't give users much control over how their grids look, since it enforces the default colour ("lightgray"), line type ("dotted"), and width (par("lwd")).

It's not a huge deal, because users can adjust these settings for individual plots by passing grid = grid(...) in the tinyplot call.

tinyplot(
    sin(0:100/10), axes = "l",
    grid = grid(col = "hotpink", lty = "solid")
)

But... thinking ahead to our goal of enabling themes (#234), maybe it's a low cost intervention to define these grid elements globally in tpar(grid.col = 'lightgray", grid.lty = "dotted", grid. lwd = 1).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions