Learn R Programming

rYWAASB (version 0.3)

bar_plot2: The second barplot of the ranks of genotypes

Description

[Stable]

  • bar_plot2() creates the 2nd barplot of the ranks of genotypes using the graphics package.

Usage

bar_plot2(datap, lowt = FALSE, verbose = FALSE)

Value

Returns an object of class gg, graphics

Arguments

datap

The data set

lowt

A parameter indicating whether lower rates of the trait is preferred or not. For grain yield e.g. Upper values is preferred. For plant height lower values e.g. is preferred.

verbose

If verbose = TRUE then some results are printed

Author

Ali Arminian abeyran@gmail.com

Examples

Run this code
# Case 1:  Higher trait values are preferred. For instance grain yield
# in cereals is a trait which its higher values are preferred and ranking
# is performed from the higher to lower values i.e. 1st, 2nd, 3rd etc
# in maize dataset.
# \donttest{
data(maize)
bar_plot2(maize) # or: bar_plot2(maize, lowt = FALSE, verbose = FALSE)
# }
# Case 2:  In this case, the lower values of the given trait are preferred.
# For instance days to maturity (dm) and plant height are traits where their
# lower values are preferred.
# \donttest{
data(dm)
bar_plot2(dm, lowt = TRUE, verbose = TRUE)
# }

Run the code above in your browser using DataLab