Learn R Programming

henna (version 0.7.5)

createLabelDFTemplate: Create a label data frame

Description

This function creates a label data frame to be used by plotting functions that label selected points.

Usage

createLabelDFTemplate(
  df,
  xCol = 1,
  yCol = 2,
  labeledPoints = NULL,
  labelOutside = FALSE,
  labXThr = NULL,
  labYThr = NULL,
  adjFunX = identity,
  adjFunY = identity,
  compFunX = `>=`,
  compFunY = `>=`
)

Value

A label data frame.

Arguments

df

A data frame.

xCol

Column representing the x axis.

yCol

Column representing the y axis.

labeledPoints

Point labels to be displayed on the plot. Default is NULL, entailing that point labels will be displayed on the basis of labXThr and labYThr, if at least one of them is not NULL.

labelOutside

Display labels for points specified by labeledPoints even if they fall outside the boundaries imposed by labXThr and labYThr. Ignored if labeledPoints is NULL or both labXThr and labYThr are NULL.

labXThr

Threshold used to plot labels based on xCol values.

labYThr

Threshold used to plot labels based on yCol values.

adjFunX

Function used to adjust xCol values. Default is identity (no adjustment will be performed).

adjFunY

Function used to adjust yCol values. Default is identity (no adjustment will be performed).

compFunX

Function used for the selection of xCol values based on labXThr.

compFunY

Function used for the selection of yCol values based on labYThr.