mirror of
https://github.com/agdamsbo/stRoke.git
synced 2024-10-29 19:01:53 +01:00
43 lines
1.1 KiB
R
43 lines
1.1 KiB
R
% Generated by roxygen2: do not edit by hand
|
|
% Please edit documentation in R/plot_olr.R
|
|
\name{plot_ord_odds}
|
|
\alias{plot_ord_odds}
|
|
\title{Forrest plot from ordinal logistic regression.}
|
|
\usage{
|
|
plot_ord_odds(
|
|
x,
|
|
title = NULL,
|
|
dec = 3,
|
|
lbls = NULL,
|
|
hori = "OR (95 \% CI)",
|
|
vert = "Variables",
|
|
short = FALSE,
|
|
input = c("model", "df")
|
|
)
|
|
}
|
|
\arguments{
|
|
\item{x}{input data.}
|
|
|
|
\item{title}{plot title}
|
|
|
|
\item{dec}{decimals for labels}
|
|
|
|
\item{lbls}{labels for variable names. Carefull, as the right order is not checked automatically!}
|
|
|
|
\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)}
|
|
|
|
\item{short}{flag to half number of ticks on horizontal axis.}
|
|
|
|
\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.}
|
|
}
|
|
\value{
|
|
gg object
|
|
}
|
|
\description{
|
|
Heavily inspired by https://www.r-bloggers.com/plotting-odds-ratios-aka-a-forrestplot-with-ggplot2/
|
|
}
|
|
\keyword{forest}
|
|
\keyword{plot}
|