Hypotheses:
In the calculation the chi-square statistic was used, in the following form:
where:
– vector of the weights for the compared groups, informing about their natural order (usually the subsequent natural numbers).
The statistic asymptotically (for large sizes) has the Chi-square distribution with degree of freedom.
The p-value, designated on the basis of the test statistic, is compared with the significance level :
In order to conduct a trend analysis in the survival curves the grouping variable must be a numerical variable in which the values of the numbers inform about the natural order of the groups. The numbers in the analysis are treated as the weights.
EXAMPLE cont. (transplant.pqs file)