R Under development (unstable) (2024-02-23 r85978 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 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. > require(lifecontingencies) Loading required package: lifecontingencies Package: lifecontingencies Authors: Giorgio Alfredo Spedicato [aut, cre] (), Christophe Dutang [ctb] (), Reinhold Kainhofer [ctb] (), Kevin J Owens [ctb], Ernesto Schirmacher [ctb], Gian Paolo Clemente [ctb] (), Ivan Williams [ctb] Version: 1.3.12 Date: BugReport: https://github.com/spedygiorgio/lifecontingencies/issues > > data(soa08Act) > > #test abbreviated arguments > axn(soa08Act, x=90, type="E") [1] 3.64881 > axn(soa08Act, x=90, type="exp") [1] 3.64881 > > axn(soa08Act, x=90, type="S", payment = "adv") [1] 4.465106 > axn(soa08Act, x=90, type="sto", payment = "arr") [1] 7.360087 > > Iaxn(soa08Act, x=90, type="E") [1] 11.88766 > > > Axn(soa08Act, x=90, type="E") [1] 0.7934636 > IAxn(soa08Act, x=90, type="E") [1] 2.975924 > DAxn(soa08Act, x=90, type="E") [1] 37.49072 > > Exn(soa08Act, x=90, n=5, type="E") [1] 0.2103644 > > axyzn(list(soa08Act, soa08Act, soa08Act), x=90:88, type="E") [1] 2.016945 > Axyzn(list(soa08Act, soa08Act, soa08Act), x=90:88, type="E") [1] 0.8858333 > > > axyzn(list(soa08Act, soa08Act), x=60:61, status="j") [1] 9.056077 > axyzn(list(soa08Act, soa08Act), x=60:61, status="l") [1] 12.99339 > > Axyzn(list(soa08Act, soa08Act), x=60:61, status="j") [1] 0.4873918 > Axyzn(list(soa08Act, soa08Act), x=60:61, status="l") [1] 0.264525 > > > #test defensive programming > try( + axn(soa08Act, x=90, type="foo1") + ) Error in match.arg(x, c("EV", "ST", "expected", "stochastic")) : 'arg' should be one of "EV", "ST", "expected", "stochastic" > > > proc.time() user system elapsed 2.42 0.21 2.62