mytable is used to produce a table of frequencies, proportion and cumulative proportions for a count variable
Usage
myTable(x)
Arguments
x
the only argument is the name of the count variable
Details
myTable is used as either a diagnostic to view the distribution of a count variable, or as a
frequency distribution display in its own right. myTable is given in Table 9.40 in Hilbe (2011).
Value
x
count value
Freq
Frequency of count
Prop
Proportion
CumProp
Cumulative proportion
Author(s)
Joseph M. Hilbe, Arizona State University, and
Jet Propulsion Laboratory, California Institute of Technology
References
Hilbe, J.M. (2011), Negative Binomial Regression, second edition, Cambridge University Press.
Hilbe, J.M. (2009), Logistic Regression Models, Chapman Hall/CRC
See Also
modelfit
Examples
data(medpar)
myTable(medpar$los)
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(COUNT)
Loading required package: msme
Loading required package: MASS
Loading required package: lattice
Loading required package: sandwich
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/COUNT/myTable.Rd_%03d_medium.png", width=480, height=480)
> ### Name: myTable
> ### Title: Frequency table
> ### Aliases: myTable
> ### Keywords: table
>
> ### ** Examples
>
> data(medpar)
> myTable(medpar$los)
x Freq Prop CumProp
1 1 126 0.0842809365 0.08428094
2 2 71 0.0474916388 0.13177258
3 3 75 0.0501672241 0.18193980
4 4 104 0.0695652174 0.25150502
5 5 123 0.0822742475 0.33377926
6 6 97 0.0648829431 0.39866221
7 7 116 0.0775919732 0.47625418
8 8 92 0.0615384615 0.53779264
9 9 74 0.0494983278 0.58729097
10 10 89 0.0595317726 0.64682274
11 11 70 0.0468227425 0.69364548
12 12 70 0.0468227425 0.74046823
13 13 43 0.0287625418 0.76923077
14 14 49 0.0327759197 0.80200669
15 15 41 0.0274247492 0.82943144
16 16 43 0.0287625418 0.85819398
17 17 29 0.0193979933 0.87759197
18 18 23 0.0153846154 0.89297659
19 19 24 0.0160535117 0.90903010
20 20 19 0.0127090301 0.92173913
21 21 18 0.0120401338 0.93377926
22 22 15 0.0100334448 0.94381271
23 23 10 0.0066889632 0.95050167
24 24 11 0.0073578595 0.95785953
25 25 4 0.0026755853 0.96053512
26 26 7 0.0046822742 0.96521739
27 27 7 0.0046822742 0.96989967
28 28 5 0.0033444816 0.97324415
29 29 3 0.0020066890 0.97525084
30 30 1 0.0006688963 0.97591973
31 31 2 0.0013377926 0.97725753
32 32 6 0.0040133779 0.98127090
33 33 2 0.0013377926 0.98260870
34 34 5 0.0033444816 0.98595318
35 36 1 0.0006688963 0.98662207
36 42 1 0.0006688963 0.98729097
37 43 1 0.0006688963 0.98795987
38 44 2 0.0013377926 0.98929766
39 46 3 0.0020066890 0.99130435
40 48 1 0.0006688963 0.99197324
41 49 1 0.0006688963 0.99264214
42 50 1 0.0006688963 0.99331104
43 52 1 0.0006688963 0.99397993
44 57 1 0.0006688963 0.99464883
45 59 1 0.0006688963 0.99531773
46 60 1 0.0006688963 0.99598662
47 63 1 0.0006688963 0.99665552
48 65 1 0.0006688963 0.99732441
49 70 1 0.0006688963 0.99799331
50 74 1 0.0006688963 0.99866221
51 91 1 0.0006688963 0.99933110
52 116 1 0.0006688963 1.00000000
>
>
>
>
>
> dev.off()
null device
1
>