% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/eventPrediction_package.R, R/eventData.R, R/dataResults.R, R/eventModel.R, R/fromParameterPlot.R
\docType{methods}
\name{plot}
\alias{plot}
\alias{plot,AnalysisResults,missing-method}
\alias{plot,EventData,missing-method}
\alias{plot,EventModel,missing-method}
\alias{plot,FromDataResults,missing-method}
\title{The plot methods for EventPrediction package}
\usage{
plot(x, y, ...)
\S4method{plot}{EventData,missing}(x, xlab = "log(t)",
ylab = "log(-log(S(t)))", main = "", ...)
\S4method{plot}{FromDataResults,missing}(x,
title = getFromDataResultsSummaryText(x, round.method = round.method,
text.width = text.width, show.predictions = show.predictions),
show.title = FALSE, text.width = 80, show.obs = FALSE,
round.method = "None", show.predictions = TRUE, pred.to.present = FALSE,
xlim = c(0, -1), ylim = NULL, include.dropouts = TRUE,
legend.position = "bottomright", custom.dates = NULL)
\S4method{plot}{EventModel,missing}(x, units = "Days",
xlab = paste("Time in study [", units, "]", sep = ""), ylab = "",
main = "", ylim = NULL, xlim = NULL, ...)
\S4method{plot}{AnalysisResults,missing}(x, text = getFromParameterText(x,
options = options), options = DisplayOptions(text.width = 110),
show.title = TRUE, show.separate.arms = !isSingleArm(x@study),
ylim = NULL)
}
\arguments{
\item{x}{Standard arguments to plot generic}
\item{y}{Standard arguments to plot generic}
\item{...}{Additional arguments for the plot function}
\item{xlab}{X axis label.}
\item{ylab}{Y axis label.}
\item{main}{Plot title}
\item{title}{The title text, by default it is \code{summary(x)}}
\item{show.title}{Logical, if TRUE, will show title in plot.}
\item{text.width}{Number of characters to wrap title text by.}
\item{show.obs}{If TRUE, add a line and points displaying the observed events.}
\item{round.method}{If the string "toMonths" then dates are rounded
to the nearest month. For the lower confidence interval value
the date 15 days earlier than the given value is rounded to the nearest
month and for the upper confidence intervalvalue the
date 15 dats later than the given value is rounded to the nearest month}
\item{show.predictions}{If TRUE show brown dashed lines at the user specified prediction
times/number of events.}
\item{pred.to.present}{If TRUE, move all predictions from past to present. Beware.}
\item{xlim}{X axis limits. If \code{x} is \code{FromDataResults} object then
c(2,10) will display from 2 to 10 months after the first
subject was recruited. Using c(0,-1) will show the entire graph}
\item{ylim}{The y-axis range for the plot}
\item{include.dropouts}{Include the cumulative dropouts on the graph (logical)}
\item{legend.position}{The position of the graph legend}
\item{custom.dates}{A vector of dates (in string or Date format) to be output on the x-axis
if NULL then default dates will be used}
\item{units}{Scale for the x-axis. "Days", "Months" or "Years"}
\item{text}{Text to display be in title, e.g. output
from the getSummaryText() function.}
\item{options}{Use this to customize the output.}
\item{show.separate.arms}{Logical, if TRUE (and if x is a two arm study) the expected event
curves for the separate arms are displayed on the graph, otherwise do not show the curves.}
}
\description{
For \code{x} an \code{EventData} object, this method will plot
a cloglog survival curve of the data. If \code{x} is an \code{EventModel}
object, this method will plot a KM curve of the data overlaid with the
survival function from the model fit.
}