Functions to print classes of the AMR package.

# S3 method for disk
plot(
  x,
  main = paste("Disk zones values of", deparse(substitute(x))),
  ylab = "Frequency",
  xlab = "Disk diffusion (mm)",
  axes = FALSE,
  ...
)

# S3 method for mic
plot(
  x,
  main = paste("MIC values of", deparse(substitute(x))),
  ylab = "Frequency",
  xlab = "MIC value",
  axes = FALSE,
  ...
)

# S3 method for mic
barplot(
  height,
  main = paste("MIC values of", deparse(substitute(height))),
  ylab = "Frequency",
  xlab = "MIC value",
  axes = FALSE,
  ...
)

# S3 method for rsi
plot(
  x,
  lwd = 2,
  ylim = NULL,
  ylab = "Percentage",
  xlab = "Antimicrobial Interpretation",
  main = paste("Resistance Overview of", deparse(substitute(x))),
  axes = FALSE,
  ...
)

# S3 method for rsi
barplot(
  height,
  col = c("chartreuse4", "chartreuse3", "brown3"),
  xlab = ifelse(beside, "Antimicrobial Interpretation", ""),
  main = paste("Resistance Overview of", deparse(substitute(height))),
  ylab = "Frequency",
  beside = TRUE,
  axes = beside,
  ...
)

Arguments

x

the coordinates of points in the plot. Alternatively, a single plotting structure, function or any R object with a plot method can be provided.

main

overall and sub title for the plot.

ylab

a label for the y axis.

xlab

a label for the x axis.

axes

logical. If TRUE, a vertical (or horizontal, if horiz is true) axis is drawn.

...

Arguments passed on to functions

height

either a vector or matrix of values describing the bars which make up the plot. If height is a vector, the plot consists of a sequence of rectangular bars with heights given by the values in the vector. If height is a matrix and beside is FALSE then each bar of the plot corresponds to a column of height, with the values in the column giving the heights of stacked sub-bars making up the bar. If height is a matrix and beside is TRUE, then the values in each column are juxtaposed rather than stacked.

ylim

limits for the y axis.

col

a vector of colors for the bars or bar components. By default, grey is used if height is a vector, and a gamma-corrected grey palette if height is a matrix.

beside

a logical value. If FALSE, the columns of height are portrayed as stacked bars, and if TRUE the columns are portrayed as juxtaposed bars.

Stable Lifecycle


The lifecycle of this function is stable. In a stable function, major changes are unlikely. This means that the unlying code will generally evolve by adding new arguments; removing arguments or changing the meaning of existing arguments will be avoided.

If the unlying code needs breaking changes, they will occur gradually. For example, a argument will be deprecated and first continue to work, but will emit an message informing you of the change. Next, typically after at least one newly released version on CRAN, the message will be transformed to an error.

Read more on Our Website!

On our website https://msberends.github.io/AMR/ you can find a comprehensive tutorial about how to conduct AMR data analysis, the complete documentation of all functions and an example analysis using WHONET data. As we would like to better understand the backgrounds and needs of our users, please participate in our survey!