当前位置:网站首页>R language survival analysis
R language survival analysis
2022-06-26 02:45:00 【Mrrunsen】
Survival analysis involves predicting when a particular event will occur . It is also called time to failure analysis or time to death analysis . for example , Predict the survival days of cancer patients or predict the time of mechanical system failure .
be known as survival Of R Packages are used for survival analysis . This package contains functions Surv(), It takes the input data as R The formula , And create a survival object in the selected variable for analysis . Then we use the function survfit() To create an analysis diagram .
Installation package
install.packages("survival")
Law
stay R The basic syntax for creating a survival analysis in is -
Surv(time,event)
survfit(formula)
The following is a description of the parameters used -
time Is the subsequent time before the event occurs .
event Indicates the status of the expected event .
A formula is the relationship between predictive variables .
Example
We will consider the existence of a package named “pbc” Data set of . It describes primary biliary cirrhosis (PBC) Patient survival data points . In the many columns that exist in the dataset , Our main concern is “ Time ” and “ state ” Field . The time represents the number of days between patient registration and the early stage of the event when the patient received a liver transplant or died .
边栏推荐
- The programmer's eight-year salary change has made netizens envious: you pay me one year's salary per month
- 记一个RestControll和Controller 引起的折磨BUG
- 如何在 ggplot2 中删除网格线(附示例)
- Fresh graduates talk about their graduation stories
- Which SMS plug-in is easy to use? The universal form needs to be tested by sending SMS
- PyQt theme
- High performance and high availability computing architecture based on microblog comments
- 二分查找
- WPF window centering & change trigger mechanism
- Possible values for @supply in kotlin
猜你喜欢

多测师拱墅肖sir_工作目录下的use websocket报错解决方案

Oracle连接问题以及解决方案

Here comes the official zero foundation introduction jetpack compose Chinese course!

第一章:渗透测试的本质信息收集

小 P 周刊 Vol.10
![[machine learning] case study of college entrance examination prediction based on multiple time series](/img/13/7368a169d07e01d86a2d2c0207ccca.png)
[machine learning] case study of college entrance examination prediction based on multiple time series

Wechat launched a web version transmission assistant. Is it really easy to use?

How to solve the problem that the iPhone 13 lock screen cannot receive the wechat notification prompt?

Redis Lua沙盒绕过命令执行(CVE-2022-0543)

Implement decorator pattern for servicecollection
随机推荐
DF reports an error stale file handle
版本管理工具使用
Fastadmin applet assistant is purchased, but the work order cannot be published in the problem work order
Technology is to be studied
What is flush software? Is online account opening safe?
图的深度优先遍历
Implementation of depth first traversal based on adjacency matrix
[defect detection] automatic defect detection of printed circuit board based on Matlab GUI [including Matlab source code 1912]
如何在 ggplot2 中向绘图中添加表格
Which securities company should I choose to open an account online? Is it safe to open an account online?
One year's work
Binary search
Digital commodity DGE -- the dark horse of wealth in digital economy
The difference between like,%, - in database query SQL
The programmer's eight-year salary change has made netizens envious: you pay me one year's salary per month
Cox 回归模型
College Students' big factory road
Scala Basics (II): variables and data types
业务流程图设计
Termux install openssh