2018-10-09 14:03:56 +02:00
|
|
|
% Generated by roxygen2: do not edit by hand
|
|
|
|
% Please edit documentation in R/plot_ord_odds.R
|
|
|
|
\name{plot_ord_odds}
|
|
|
|
\alias{plot_ord_odds}
|
2019-12-03 14:40:05 +01:00
|
|
|
\title{Forrest plot from ordinal logistic regression.}
|
2018-10-09 14:03:56 +02:00
|
|
|
\usage{
|
2019-11-08 09:45:15 +01:00
|
|
|
plot_ord_odds(x, title = NULL, dec = 3, lbls = NULL,
|
|
|
|
hori = "OR (95 \% CI)", vert = "Variables", short = FALSE,
|
2019-12-03 14:27:00 +01:00
|
|
|
input = c("model", "df"))
|
2018-10-09 14:03:56 +02:00
|
|
|
}
|
|
|
|
\arguments{
|
2018-10-23 14:54:21 +02:00
|
|
|
\item{x}{input data.}
|
2018-10-09 14:03:56 +02:00
|
|
|
|
|
|
|
\item{title}{plot title}
|
|
|
|
|
|
|
|
\item{dec}{decimals for labels}
|
|
|
|
|
|
|
|
\item{lbls}{labels for variable names. Carefull, as the right order is not checked automatically!}
|
2018-10-10 11:49:52 +02:00
|
|
|
|
2019-11-08 09:45:15 +01:00
|
|
|
\item{hori}{labels the horizontal axis (this i the y axis as the plot is rotated)}
|
|
|
|
|
|
|
|
\item{vert}{labels the horizontal axis (this i the x axis as the plot is rotated)}
|
|
|
|
|
2018-10-10 11:49:52 +02:00
|
|
|
\item{short}{flag to half number of ticks on horizontal axis.}
|
2018-10-23 14:54:21 +02:00
|
|
|
|
2019-12-03 14:27:00 +01:00
|
|
|
\item{input}{can be either "model", which is a olr model (polr()), or "df", which is a dataframe whith three columns for OR, lower CI and upper CI.}
|
2018-10-09 14:03:56 +02:00
|
|
|
}
|
|
|
|
\description{
|
|
|
|
Heavily inspired by https://www.r-bloggers.com/plotting-odds-ratios-aka-a-forrestplot-with-ggplot2/
|
|
|
|
}
|
|
|
|
\keyword{forestplot}
|