createVarDistPlot: Create distribution plot

View source: R/analyzeDistribution.R

createVarDistPlotR Documentation

Create distribution plot

Description

Create distribution plot for one of the additional variable or the percentage of the species present in the supertaxa.

Usage

createVarDistPlot(data, varName = "var", varType = "var1",
    percent = c(0, 1), textSize = 12)

Arguments

data

dataframe contains data for plotting (see ?createVariableDistributionData, ?createVariableDistributionDataSubset or ?createPercentageDistributionData)

varName

name of the variable that need to be analyzed (either name of variable 1 or variable 2 or "percentage of present taxa"). Default = "var".

varType

type of variable (either "var1", "var2" or "presSpec"). Default = "var1".

percent

range of percentage cutoff (between 0 and 1). Default = c(0,1)

textSize

text size of the distribution plot (in px). Default = 12.

Value

A distribution plot for the selected variable as a ggplot object

Author(s)

Vinh Tran tran@bio.uni-frankfurt.de

See Also

mainLongRaw, createVariableDistributionData, createVariableDistributionDataSubset, createPercentageDistributionData

Examples

data("mainLongRaw", package="PhyloProfile")
data <- createVariableDistributionData(
    mainLongRaw, c(0, 1), c(0.5, 1)
)
varName <- "Variable abc"
varType <- "var1"
percent <- c(0,1)
textSize <- 12
createVarDistPlot(
    data,
    varName,
    varType,
    percent,
    textSize
)

BIONF/PhyloProfile documentation built on Dec. 18, 2024, 7:33 a.m.