Skip to contents

This is a model object for a split-duration model of the Powell & Thyne coups. It is used in several example code sections to speed up package testing by eliminating the need to re-estimate a model each time.

Usage

model.coups

Format

An object of class spdur.

Source

For information on the data used in this model, see the data documentation, coups.

Examples

data(model.coups)
str(model.coups)
#> List of 17
#>  $ coefficients:List of 3
#>   ..$ duration: Named num [1:2] 4.002 0.206
#>   .. ..- attr(*, "names")= chr [1:2] "(Intercept)" "polity2"
#>   ..$ risk    : Named num [1:2] 6.528 0.897
#>   .. ..- attr(*, "names")= chr [1:2] "(Intercept)" "polity2"
#>   ..$ distr   : Named num -0.032
#>   .. ..- attr(*, "names")= chr "log(alpha)"
#>  $ vcov        : num [1:5, 1:5] 0.05646 0.00191 0.42977 0.05096 0.01866 ...
#>   ..- attr(*, "dimnames")=List of 2
#>   .. ..$ : chr [1:5] "(Intercept)" "polity2" "(Intercept)" "polity2" ...
#>   .. ..$ : chr [1:5] "(Intercept)" "polity2" "(Intercept)" "polity2" ...
#>  $ logL        : num -320
#>  $ base        :List of 3
#>   ..$ coefficients: num [1:3] 4.553 0.117 0.113
#>   ..$ vcv         : num [1:3, 1:3] 0.049663 0.003077 0.016996 0.003077 0.000551 ...
#>   ..$ logL        : num -334
#>  $ se          : Named num [1:5] 0.2376 0.0304 3.2556 0.4084 0.119
#>   ..- attr(*, "names")= chr [1:5] "(Intercept)" "polity2" "(Intercept)" "polity2" ...
#>  $ zstat       : Named num [1:5] 16.84 6.779 2.005 2.196 -0.269
#>   ..- attr(*, "names")= chr [1:5] "(Intercept)" "polity2" "(Intercept)" "polity2" ...
#>  $ pval        : Named num [1:5] 0.00 1.21e-11 4.50e-02 2.81e-02 7.88e-01
#>   ..- attr(*, "names")= chr [1:5] "(Intercept)" "polity2" "(Intercept)" "polity2" ...
#>  $ mf.dur      :'data.frame':	4782 obs. of  2 variables:
#>   ..$ duration: num [1:4782] 1 1 1 1 1 1 1 1 1 1 ...
#>   ..$ polity2 : int [1:4782] 0 5 8 9 -9 -4 -4 -7 9 -8 ...
#>   ..- attr(*, "terms")=Classes 'terms', 'formula'  language duration ~ polity2
#>   .. .. ..- attr(*, "variables")= language list(duration, polity2)
#>   .. .. ..- attr(*, "factors")= int [1:2, 1] 0 1
#>   .. .. .. ..- attr(*, "dimnames")=List of 2
#>   .. .. .. .. ..$ : chr [1:2] "duration" "polity2"
#>   .. .. .. .. ..$ : chr "polity2"
#>   .. .. ..- attr(*, "term.labels")= chr "polity2"
#>   .. .. ..- attr(*, "order")= int 1
#>   .. .. ..- attr(*, "intercept")= int 1
#>   .. .. ..- attr(*, "response")= int 1
#>   .. .. ..- attr(*, ".Environment")=<environment: R_GlobalEnv> 
#>   .. .. ..- attr(*, "predvars")= language list(duration, polity2)
#>   .. .. ..- attr(*, "dataClasses")= Named chr [1:2] "numeric" "numeric"
#>   .. .. .. ..- attr(*, "names")= chr [1:2] "duration" "polity2"
#>  $ mf.risk     :'data.frame':	4782 obs. of  2 variables:
#>   ..$ atrisk : num [1:4782] 0 1 0 0 0 1 0 0 0 1 ...
#>   ..$ polity2: int [1:4782] 0 5 8 9 -9 -4 -4 -7 9 -8 ...
#>   ..- attr(*, "terms")=Classes 'terms', 'formula'  language atrisk ~ polity2
#>   .. .. ..- attr(*, "variables")= language list(atrisk, polity2)
#>   .. .. ..- attr(*, "factors")= int [1:2, 1] 0 1
#>   .. .. .. ..- attr(*, "dimnames")=List of 2
#>   .. .. .. .. ..$ : chr [1:2] "atrisk" "polity2"
#>   .. .. .. .. ..$ : chr "polity2"
#>   .. .. ..- attr(*, "term.labels")= chr "polity2"
#>   .. .. ..- attr(*, "order")= int 1
#>   .. .. ..- attr(*, "intercept")= int 1
#>   .. .. ..- attr(*, "response")= int 1
#>   .. .. ..- attr(*, ".Environment")=<environment: R_GlobalEnv> 
#>   .. .. ..- attr(*, "predvars")= language list(atrisk, polity2)
#>   .. .. ..- attr(*, "dataClasses")= Named chr [1:2] "numeric" "numeric"
#>   .. .. .. ..- attr(*, "names")= chr [1:2] "atrisk" "polity2"
#>  $ Y           : num [1:4782, 1:5] 0 1 0 0 0 1 0 0 0 1 ...
#>   ..- attr(*, "dimnames")=List of 2
#>   .. ..$ : chr [1:4782] "5007" "5006" "5570" "5039" ...
#>   .. ..$ : chr [1:5] "atrisk" "duration" "last" "t.0" ...
#>   ..- attr(*, "last")= chr "end.spell"
#>   ..- attr(*, "t.0")= chr "t.0"
#>   ..- attr(*, "fail")= chr "failure"
#>  $ na.action   : 'omit' Named int [1:1046] 5 6 17 18 19 20 24 32 51 57 ...
#>   ..- attr(*, "names")= chr [1:1046] "5" "129" "5538" "5506" ...
#>  $ call        : language spdur(duration = duration ~ polity2, atrisk = atrisk ~ polity2, data = dur.coups)
#>  $ formula     : NULL
#>  $ terms       : NULL
#>  $ distr       : chr "weibull"
#>  $ obs         : int 4782
#>  $ n.terms     :List of 2
#>   ..$ duration: int 2
#>   ..$ risk    : int 2
#>  - attr(*, "class")= chr "spdur"