Learn R Programming

quickPlot (version 1.0.2)

.identifyGrobToPlot: Identify where to get the grob from

Description

Internal function.

Usage

.identifyGrobToPlot(toPlot, sGrob, takeFromPlotObj)

# S4 method for ANY,.quickPlotGrob .identifyGrobToPlot(toPlot, sGrob, takeFromPlotObj)

Arguments

toPlot

The object to plot. Should be a single layer if from a multi-layer object such as a RasterStack.

sGrob

quickPlot grob object

takeFromPlotObj

Logical. Should the data come from the argument passed into Plot (TRUE), or from the (.quickPlotEnv) (FALSE).

Author

Eliot McIntire

Details

Because the Plot function can use the global environment as a source of objects to plot, not just the call itself, this function identifies where the data for the grob should come from, the current call or the global environment.