[R] adding column to a matrix

From: raymond chiruka <rtchiruka_at_yahoo.com>
Date: Tue, 01 May 2007 04:25:18 -0700 (PDT)


l have the following dataset and would like to calculate the actual survival time by   if censoring time > survival time then actual survival time =survival time else its= censoring time.

        treatmentgrp strata  censoringTime    survivalTime     censoring   actualsurvivaltim
     [1,]             1      1       1.012159           1137.80922                0

[2,] 2 2 32.971439 247.21786 0
[3,] 2 1 85.758253 797.04949 0
[4,] 1 1 16.999171 78.92309 0

  l used matrix to genarate the data
  thanks in advance              


        [[alternative HTML version deleted]]



R-help_at_stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Tue 01 May 2007 - 17:40:06 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 01 May 2007 - 18:31:33 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.