From aedcf968c34bf2fec0dc5f80e79441ce288f9605 Mon Sep 17 00:00:00 2001 From: Alec Loudenback Date: Mon, 17 Jun 2024 22:41:35 -0500 Subject: [PATCH] Built site for gh-pages --- .DS_Store | Bin 6148 -> 0 bytes .nojekyll | 2 +- all-posts.html | 44 +++--- all-posts.xml | 26 ++-- assets/.DS_Store | Bin 6148 -> 0 bytes benchmarks.html | 137 ++++++++--------- blog.html | 14 +- examples.html | 30 ++-- examples/.DS_Store | Bin 10244 -> 0 bytes packages.html | 139 ++++++++++++++++-- posts/.DS_Store | Bin 12292 -> 0 bytes .../index_files/.DS_Store | Bin 6148 -> 0 bytes posts/policy-diffeq/index_files/.DS_Store | Bin 6148 -> 0 bytes search.json | 6 +- sitemap.xml | 60 ++++---- styles.css | 6 + 16 files changed, 292 insertions(+), 172 deletions(-) delete mode 100644 .DS_Store delete mode 100644 assets/.DS_Store delete mode 100644 examples/.DS_Store delete mode 100644 posts/.DS_Store delete mode 100644 posts/bayesian-claims-demo/index_files/.DS_Store delete mode 100644 posts/policy-diffeq/index_files/.DS_Store diff --git a/.DS_Store b/.DS_Store deleted file mode 100644 index 1b4986de91cad0eb66e593064d8dec122df52fe7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHKu};G<5IvWI3Jeq`7?Au66$5O9Dttjd04S}XQlnIAkvjT!5F=FL3lJkCBMUQX zyD;+3wu;k)vLQfsk?%S7o&EBn*f9~Q`c8JCz;9E4zugr&qdu-S&40glx0Ct)B#q-{H*KQ5a{uzG-!>kO@-eM% zV|tgtIx#XB0*g$WhTxJ=kGiO5))KY9^;{Ga^0^t$_~gb)(oar{;zC~PKr^pp@JXT1 zoI2`ocQ4x;avALmr(>s0kRP%rj>ya(8J>R?b9XR%n@*rhhniVssQNT0jtco)zdx2H zj!(gOA+N=eAwSxbWu9NqA2saRY?XC~;za>bKopoM!0UrXVT?Q)hj!_Jvqu168O_#E z=U)oW(Hj-v5ukKL2NvCategories
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+

 
diff --git a/all-posts.xml b/all-posts.xml index 12b2e1c..eb262f2 100644 --- a/all-posts.xml +++ b/all-posts.xml @@ -2100,7 +2100,7 @@ using Pluto; Pluto.run() financemodels assets https://JuliaActuary.org/posts/cashflow-interactive/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Universal Life Policy Account Mechanics as a Differential Equation @@ -2588,7 +2588,7 @@ annotate!(viz[2], (0.055, 7000, Plots.text("Doesn't lapse \nbefore age 100", 8, actuaryutilities tutorial https://JuliaActuary.org/posts/policy-diffeq/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT US Treasury Comparison Tool @@ -2626,7 +2626,7 @@ using Pluto; Pluto.run() financemodels tutorial https://JuliaActuary.org/posts/treasury-interactive/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Bayesian Markov-Chain-Monte-Carlo and Claims Data @@ -6973,7 +6973,7 @@ Quantiles statistics bayesian https://JuliaActuary.org/posts/bayesian-claims-demo/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Nested Projection Mechanics @@ -8187,7 +8187,7 @@ end actuaryutilities tutorial https://JuliaActuary.org/posts/nested-policy-projections/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Using MortaltiyTables.jl with DataFrames @@ -8820,7 +8820,7 @@ sample_data dataframes tutorial https://JuliaActuary.org/posts/mortalitytables-and-dataframes/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Poisson approximation to Binomial @@ -9032,7 +9032,7 @@ end statistics experience-analysis https://JuliaActuary.org/posts/poisson-approximation/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Bayesian vs Limited Fluctuation Experience Analysis @@ -10156,7 +10156,7 @@ end statistics experience-analysis https://JuliaActuary.org/posts/bayes-vs-limited-fluctuation/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Fitting Rate Data to Yield Curves @@ -10394,7 +10394,7 @@ gif(anim, "anim_fps2.gif", fps=2) financemodels tutorial https://JuliaActuary.org/posts/fitting-yield-curves/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Fitting survival data with MortaltityTables.jl @@ -10876,7 +10876,7 @@ plot!(plt2, km.events.time, model(km.events.time, mfit.param), labels="Theoretic survival tutorial https://JuliaActuary.org/posts/fitting-survival-data/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Interactive AAA Economic Scenario Generator @@ -10920,7 +10920,7 @@ using Pluto; Pluto.run() modeling scenario-generator https://JuliaActuary.org/posts/academy-generator-rates/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Stochastic claims projections demo @@ -11187,7 +11187,7 @@ hist(v, benchmark tutorial https://JuliaActuary.org/posts/stochastic-mortality/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT Exposure Calculation with ExperienceAnalysis.jl @@ -11471,7 +11471,7 @@ df[:, [:exposure, :exposure_fraction]] dataframes tutorial https://JuliaActuary.org/posts/exposures-example/ - Mon, 17 Jun 2024 03:38:21 GMT + Tue, 18 Jun 2024 03:41:32 GMT diff --git a/assets/.DS_Store b/assets/.DS_Store deleted file mode 100644 index 97479889481cb89f89e8a1306b9dc984886e79a0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHK!AiqG5S^_RQYzAm;4v3(9_$~)67NF&0I991kTwM?UeiD54+wfzf1`L(&whfR z;K?^TOWl}M#Dj>;!0g-X&g{OtEtxJ6na)MOP1GWy0M1xzps6sPXD?aJjcfpoT_dG4 zN@z&aG$}>vz+Y5=&#r+JlXLUVuiZV#MiZfYyH_1G%Hp_}WC0 zk&~gn^D`4zr<5}Mt};4L6MuI0R-EHl1|25 zK8)MhxEqSGyJP*(hLec|wN(XFfuaIy^4Q|~f3W)gUrf>`RX`Q^R|=SV+>JYUC0AQZ wFUPeugdfA%I4&1lrl4a>F=DwCZ^Nx&Jmd~Aa+nKZ1g3uktPI+y0>7%jJEuK!@Bjb+ diff --git a/benchmarks.html b/benchmarks.html index a16d7c6..c589cc6 100644 --- a/benchmarks.html +++ b/benchmarks.html @@ -242,6 +242,9 @@

Benchmarks

After the original user submitted a proposal, others chimed in and submitted versions in their favorite languages. I have collected those versions, and run them on a consistent set of hardware.

Some submissions were excluded because from the benchmarks they involved an entirely different approach, such as memoizing the function calls[^1].

+
+
[ Info: Precompiling CSV [336ed68f-0bac-5ca0-87d4-7b16caf5d00b]
+
@@ -450,84 +453,84 @@

Benchmarks

- + - + - + - + - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Figure 1 diff --git a/blog.html b/blog.html index 292e495..5f47833 100644 --- a/blog.html +++ b/blog.html @@ -243,7 +243,7 @@
Categories
-
+
-
+
-
+
-
+
-
+
-
+
-
+

 
diff --git a/examples.html b/examples.html index b8504a1..42059c7 100644 --- a/examples.html +++ b/examples.html @@ -262,7 +262,7 @@
Categories
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+

diff --git a/examples/.DS_Store b/examples/.DS_Store deleted file mode 100644 index a831363c6f7c17258ce5d605724ff49d911e779f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 10244 zcmeHMO=uHA6n>i)TCG+q(IQI8Me$%ti+B@>C4vX3g@T~SB5K6NcIP(SY9#)huc{PMZ;rt_z!POCM^hA~0X*4c6|f3e1*`&A0jt2@r~u|{ zPK`~{+PhW2Dqt1(sQ`};5nOCz$`+*+LkDhR3jkY>*COE=`v8H7C>v9@D6N2^Ou2h- z6x2~$3`fH8dxW#Y#*{5eE8*lwI610jN9|A?Q9E!Ek)52FwDxWlunJTwzB<{ z+StG6@ofZe$H=9T;epQHl$$Gv0uDdA=na)~{~&mS zcf&OEZUMhZDj@Pl(F;aYf8lot^pyfUZ!)IoH{MV>*H_;{?Z+io5B2FR{UHs0w7~p! z!=K#a*?W1M*+v!53E|BI_;EyY?@t(>4K2s~p>@9TJ@a*6o5eifqkf%tuo4XZp%vyI zuHruh<{9wj5iliuj;LNUBh;;2_k-2BueQ(D-6_ZQTJ6`VTW1~wZ}66jx%sz#89MuW@l0_t}9q*gwE(zWqu{!U!`5Rl8%Dg?}E8|!YyurKaG5fo%25;6N z$vqj2qj=5>->axceDL^|tBL`7R=3&mbbU%MlJ7ptKC!7b>ap^>$~1JO66?4ZDzRSW zwE~Zj97ib;M+Io+(hzdUc>!^>rUy9(c;yhF6kW5$&r26h$(RaMQYE@JSCXNR)4}@e z7IOyoA<>IOTov$+b(w@tImA@06;<fFYbmyUjy{oixly61x64c_vUBn+m!%3;pD-r-r{*Xz7c-;Chx z5v%h)J2Y3B4?W{69u9&xc!vt?@BcON9EKF(^Z%3U|Nk#C*_&0sD)4VA;MB)^<6YpU z&ep3~@>zQX*A-lxIA2j(0l|&4@O!btz!yG_KcwD?MUi@rDO;3Qz=0ERSh+#@<9`O! rIJ+?Bg@$Qvo`?Oou>!FBe_l1zI6ctk{9wCxeYF#;1jD~}|L^_){G#($ diff --git a/packages.html b/packages.html index 82d53f9..db0e548 100644 --- a/packages.html +++ b/packages.html @@ -181,7 +181,7 @@

On this page

  • ExperienceAnalysis.jl
  • EconomicScenarioGenerators.jl @@ -689,20 +689,131 @@

    ExperienceAnalysis.j

    Meeting your exposure calculation needs.

    -

    QuickStart

    -
    using ExperienceAnalysis
    -using Dates
    +

    Quickstart

    +
    df = DataFrame(
    +    policy_id = 1:3,
    +    issue_date = [Date(2020,5,10), Date(2020,4,5), Date(2019, 3, 10)],
    +    end_date = [Date(2022, 6, 10), Date(2022, 8, 10), Date(2022,12,31)],
    +    status = ["claim", "lapse", "inforce"]
    +)
    +
    +df.policy_year = exposure.(
    +    ExperienceAnalysis.Anniversary(Year(1)),
    +    df.issue_date,
    +    df.end_date,
    +    df.status .== "claim"; # continued exposure
    +    study_start = Date(2020, 1, 1),
    +    study_end = Date(2022, 12, 31)
    +)
    +
    +df = flatten(df, :policy_year)
     
    -issue = Date(2016, 7, 4)
    -termination = Date(2020, 1, 17)
    -basis = ExperienceAnalysis.Anniversary(Year(1))
    -exposure(basis, issue, termination)
    -

    This will return an array of tuples with a from and to date:

    -
    4-element Array{NamedTuple{(:from, :to),Tuple{Date,Date}},1}:
    - (from = Date("2016-07-04"), to = Date("2017-07-04"))
    - (from = Date("2017-07-04"), to = Date("2018-07-04"))
    - (from = Date("2018-07-04"), to = Date("2019-07-04"))
    - (from = Date("2019-07-04"), to = Date("2020-01-17"))
    +df.exposure_fraction = + map(e -> yearfrac(e.from, e.to + Day(1), DayCounts.Thirty360()), df.policy_year) +# + Day(1) above because DayCounts has Date(2020, 1, 1) to Date(2021, 1, 1) as an exposure of 1.0 +# here we end the interval at Date(2020, 12, 31), so we need to add a day to get the correct exposure fraction.
    + ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    policy_id
    Int64
    issue_date
    Date
    end_date
    Date
    status
    String
    policy_year
    @NamedTuple{from::Date, to::Date, policy\_timestep::Int64}
    exposure_fraction
    Float64
    12020-05-102022-06-10claim(from = Date(“2020-05-10”), to = Date(“2021-05-09”), policy_timestep = 1)1.0
    12020-05-102022-06-10claim(from = Date(“2021-05-10”), to = Date(“2022-05-09”), policy_timestep = 2)1.0
    12020-05-102022-06-10claim(from = Date(“2022-05-10”), to = Date(“2023-05-09”), policy_timestep = 3)1.0
    22020-04-052022-08-10lapse(from = Date(“2020-04-05”), to = Date(“2021-04-04”), policy_timestep = 1)1.0
    22020-04-052022-08-10lapse(from = Date(“2021-04-05”), to = Date(“2022-04-04”), policy_timestep = 2)1.0
    22020-04-052022-08-10lapse(from = Date(“2022-04-05”), to = Date(“2022-08-10”), policy_timestep = 3)0.35
    32019-03-102022-12-31inforce(from = Date(“2020-01-01”), to = Date(“2020-03-09”), policy_timestep = 1)0.191667
    32019-03-102022-12-31inforce(from = Date(“2020-03-10”), to = Date(“2021-03-09”), policy_timestep = 2)1.0
    32019-03-102022-12-31inforce(from = Date(“2021-03-10”), to = Date(“2022-03-09”), policy_timestep = 3)1.0
    32019-03-102022-12-31inforce(from = Date(“2022-03-10”), to = Date(“2022-12-31”), policy_timestep = 4)0.808333

    Available Exposure Basis

    diff --git a/posts/.DS_Store b/posts/.DS_Store deleted file mode 100644 index 077930a3570a55018ca878c802349f38f8b1f636..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 12292 zcmeHNU1(fI6rP);CK62(vQ=xMu5T3*X}|~~=vpE^nIb_dL1;F+n>KYfyUlL?d@(|` zFN#$fDuGIWXc7EDMUhsl`yfRHF^IIqzgDo8fHc&CK8WadX6~JPW|Q2^-31YQFWftu zxpQXb`_7qj=FE){!r3yB?h#^>5TXe;m9016u~&$AGfH;Rd%Blh^{8=h58=k|Rw2ej z5_d{uL^tZzy6Vt??JBFGGxBnd8jEPb%-`6*s%@3o8 zrtfa)*z?=^(+`Ppv@W6TIDflsU#EI2L>u0xAQ4>=0}%re0}%re1J@!06nk+sRm6K$ z8$BZiA_lH$2FO3eaZ{Oa%UM-Q*MSFZ;pshX;pK(j$OB|u+$|GsIjc%33K=PiQi(cl zis2}6)W@kg%7k0as#1vyM~Mr^9oca+6i1E@xwvdDoP;W)XT(6nz;Xs2KvmVbcUtG( zXUi||zD&7y)x8yV_6(%*xq_NvnTieaOrV5Zo=ygK;1r;U{C`|b;_pf1@LANPWv-vh z?qJe&=WYro&CdxQDc|ay6NDH)m-o5&_K&HnR}>c^dNAR=*CKF=+Yha>=-Z(d3zM;9PsYl;Ve(Zm~C?LM#lVA^llfspwldDJqaCK z>iWF}V6l|sxKi!&?ef$xgtV{2sliJ#E=J3-4ZNa^NyE<(R?<+n@J~HGpI3nPNQ+s# z&l&owzxUa2(j52S4O*We#^?I|w0Pn<7kh{v4E*&8!XJ~UX?2rNA4NGM{aYUO1$S*1 z!NHh;zWLy*VPrY>rMc|~t|||0JvK+4J@K^X;jQHj+|BP0?%P+uO&lm)d#B#y>)j{^ z8=G!(nY3HO-N8_I37%7aMBo)8J99pN-fZNbiOxu~mSrkR7F@ z9jW!R3-2gajFKHyu;<)$2JBVQ3+L?p1Ddm{dh&hBGnWs0OjXg7!H=_<>}-Q%WEB2i zt|Bm$M2+HQ8jR%dx66#N!de!$hLh%e^d8gSTSAP_EvEnUQICfZJs9}c6MV!&(<0Kq zJR<$=ZUb-s!pFg_Iljl&Ykddw&+&ZrxyBP9Va&h(0?ofg&L7bmnw!GhONj5Z|C8Ux z321j8lW8hF(c#L)+m~~3-Pv|$TQ5EwH?{8wdXB#kC z%W`~s-qJQ0Lf&7A5B@Uk`+3W`uZX(@zn#GaofOySvhVMK z<8f;|_mf_Q7Be;U-gSu3-YnNx;CNV(3Tx%gDmHLm_#Qa!`mgj_3^@6v2lKM)m39Y%kG9s*7w2f}LG7ojo*QTD z?hkaNt-3#hw?XO8VvIM+O~=4n3d|)Xcf_JvL3v}fbUyhyc(Rt|ynM4)+fE31-#hL< zrFpQHH*j}K+$}5MR`Cm&sex6LzX#U9_8i~OojUhkL&nE6cl5)Yn{@`t7&ycNrUf0O zpsONwA0yCO9?{7r4mZBADU2+~cj~brKhLxro7?fpJ6IgHls9lU?jzi7G6K`CSDm8L z{*lfaMzF%^^bGq0Q;V$+_f)MM- zIPkxJ^!@+g)&KubHi{k*0}%uNPX?TZzJb0iz_wbNMBm!uxQB3i7uw3^c*sxjDCO51 xl=4$N%FV28f_|fJR+adL>tFvT0LvI^c+M#PuexjC@iB`3e80i>H~-D}{}0Z=*=Ya( diff --git a/posts/bayesian-claims-demo/index_files/.DS_Store b/posts/bayesian-claims-demo/index_files/.DS_Store deleted file mode 100644 index ee1b0999fa6947bb93f9ea9423228eeb9218350a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHKK~BR!475uRK|RnT7o`0FhrWPNg*#F|03jtsN|XvwiDMqaTlfL*;0uh`rld-W z#06EAE!ng2+8bw5#WfM}d{fMbrbLuL1xKea10wsPJsFutHaVX0OiQ|?6}?d1i+0B$ zG9d46LXY%BC2gqt{;H~+EgqVB-6?xdWZh(0UNt!)laJerx6iZp>;31}P4S25^{Q7z zf?wB?3eRZ<@Id^JK%~KqGw`nrd;tdKQ#Jqq diff --git a/posts/policy-diffeq/index_files/.DS_Store b/posts/policy-diffeq/index_files/.DS_Store deleted file mode 100644 index 3df5906b84fb268d3b32de2a435f4e2231a1e650..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHKK~BR!4D^N`f_flFj{5-){lQX&7xV)VQqoF^QXzWJleoi~kMID#z<6y+sw7BU zP=##Co{iVuIFl-_iO4PY<$@?9q7=%QoWqO=@3RghQ4eprc*Y~G>54Y=M9m=D9H+g-(3UFNQ~&+db+uUCx6Q6s_C#dU=6O-K1tQZVd)|Iryj@S9+qC5`qIa7?6)ApQ zYbsIm9Tm`Oq|!l5zsA@1m#-Q};=Zfmj4`mFBonZWQz{C*%IDU6|#k`BMuxS-exN;)|m zKAhg!>4f6q-EqE;;pBp#S!2K$IA-8XE;H``H`DX~agtpb1IEC=V!+MvRldX{X>T1o v9QRrey@j%HTqk%)!6LR|#BwXXghqki^8y$YJ3)9L_D3MnV8$5uQwBZ(KB!Z& diff --git a/search.json b/search.json index 73a2d73..3f118ec 100644 --- a/search.json +++ b/search.json @@ -53,7 +53,7 @@ "href": "packages.html#experienceanalysis.jl", "title": "Packages", "section": "ExperienceAnalysis.jl", - "text": "ExperienceAnalysis.jl\n\nMeeting your exposure calculation needs.\n\n\nQuickStart\nusing ExperienceAnalysis\nusing Dates\n\nissue = Date(2016, 7, 4)\ntermination = Date(2020, 1, 17)\nbasis = ExperienceAnalysis.Anniversary(Year(1))\nexposure(basis, issue, termination)\nThis will return an array of tuples with a from and to date:\n4-element Array{NamedTuple{(:from, :to),Tuple{Date,Date}},1}:\n (from = Date(\"2016-07-04\"), to = Date(\"2017-07-04\"))\n (from = Date(\"2017-07-04\"), to = Date(\"2018-07-04\"))\n (from = Date(\"2018-07-04\"), to = Date(\"2019-07-04\"))\n (from = Date(\"2019-07-04\"), to = Date(\"2020-01-17\"))\n\n\nAvailable Exposure Basis\n\nExperienceAnalysis.Anniversary(period) will give exposures periods based on the first date\nExperienceAnalysis.Calendar(period) will follow calendar periods (e.g. month or year)\nExperienceAnalysis.AnniversaryCalendar(period,period) will split into the smaller of the calendar or policy period.\n\nWhere period is a Period Type from the Dates standard library.\nCalculate exposures with exposures(basis,from,to,continue_exposure).\n\ncontinue_exposures indicates whether the exposure should be extended through the full exposure period rather than terminate at the to date.\n\nExperienceAnalysis package on GitHub 🡭" + "text": "ExperienceAnalysis.jl\n\nMeeting your exposure calculation needs.\n\n\nQuickstart\ndf = DataFrame(\n policy_id = 1:3,\n issue_date = [Date(2020,5,10), Date(2020,4,5), Date(2019, 3, 10)],\n end_date = [Date(2022, 6, 10), Date(2022, 8, 10), Date(2022,12,31)],\n status = [\"claim\", \"lapse\", \"inforce\"]\n)\n\ndf.policy_year = exposure.(\n ExperienceAnalysis.Anniversary(Year(1)),\n df.issue_date,\n df.end_date,\n df.status .== \"claim\"; # continued exposure\n study_start = Date(2020, 1, 1),\n study_end = Date(2022, 12, 31)\n)\n\ndf = flatten(df, :policy_year)\n\ndf.exposure_fraction =\n map(e -> yearfrac(e.from, e.to + Day(1), DayCounts.Thirty360()), df.policy_year) \n# + Day(1) above because DayCounts has Date(2020, 1, 1) to Date(2021, 1, 1) as an exposure of 1.0\n# here we end the interval at Date(2020, 12, 31), so we need to add a day to get the correct exposure fraction.\n\n\n\n\n\n\n\n\n\n\n\npolicy_idInt64\nissue_dateDate\nend_dateDate\nstatusString\npolicy_year@NamedTuple{from::Date, to::Date, policy\\_timestep::Int64}\nexposure_fractionFloat64\n\n\n\n\n1\n2020-05-10\n2022-06-10\nclaim\n(from = Date(“2020-05-10”), to = Date(“2021-05-09”), policy_timestep = 1)\n1.0\n\n\n1\n2020-05-10\n2022-06-10\nclaim\n(from = Date(“2021-05-10”), to = Date(“2022-05-09”), policy_timestep = 2)\n1.0\n\n\n1\n2020-05-10\n2022-06-10\nclaim\n(from = Date(“2022-05-10”), to = Date(“2023-05-09”), policy_timestep = 3)\n1.0\n\n\n2\n2020-04-05\n2022-08-10\nlapse\n(from = Date(“2020-04-05”), to = Date(“2021-04-04”), policy_timestep = 1)\n1.0\n\n\n2\n2020-04-05\n2022-08-10\nlapse\n(from = Date(“2021-04-05”), to = Date(“2022-04-04”), policy_timestep = 2)\n1.0\n\n\n2\n2020-04-05\n2022-08-10\nlapse\n(from = Date(“2022-04-05”), to = Date(“2022-08-10”), policy_timestep = 3)\n0.35\n\n\n3\n2019-03-10\n2022-12-31\ninforce\n(from = Date(“2020-01-01”), to = Date(“2020-03-09”), policy_timestep = 1)\n0.191667\n\n\n3\n2019-03-10\n2022-12-31\ninforce\n(from = Date(“2020-03-10”), to = Date(“2021-03-09”), policy_timestep = 2)\n1.0\n\n\n3\n2019-03-10\n2022-12-31\ninforce\n(from = Date(“2021-03-10”), to = Date(“2022-03-09”), policy_timestep = 3)\n1.0\n\n\n3\n2019-03-10\n2022-12-31\ninforce\n(from = Date(“2022-03-10”), to = Date(“2022-12-31”), policy_timestep = 4)\n0.808333\n\n\n\n\n\nAvailable Exposure Basis\n\nExperienceAnalysis.Anniversary(period) will give exposures periods based on the first date\nExperienceAnalysis.Calendar(period) will follow calendar periods (e.g. month or year)\nExperienceAnalysis.AnniversaryCalendar(period,period) will split into the smaller of the calendar or policy period.\n\nWhere period is a Period Type from the Dates standard library.\nCalculate exposures with exposures(basis,from,to,continue_exposure).\n\ncontinue_exposures indicates whether the exposure should be extended through the full exposure period rather than terminate at the to date.\n\nExperienceAnalysis package on GitHub 🡭" }, { "objectID": "packages.html#economicscenariogenerators.jl", @@ -970,14 +970,14 @@ "href": "benchmarks.html", "title": "Benchmarks", "section": "", - "text": "Inspired by the discussion in the ActuarialOpenSource GitHub community discussion, folks started submitted solutions to what someone referred to as the “Life Modeling Problem”. This user submitted a short snippet for consideration of a representative problem.\n\n\nAfter the original user submitted a proposal, others chimed in and submitted versions in their favorite languages. I have collected those versions, and run them on a consistent set of hardware.\nSome submissions were excluded because from the benchmarks they involved an entirely different approach, such as memoizing the function calls[^1].\n\n\n\n\nTable 1: Benchmarks for the Life Modeling Problem in nanoseconds (lower times are better).\n\n\n\n18×6 DataFrame\n\n\n\nRow\nlang\nalgorithm\nfunction_name\nmedian\nmean\nrelative_mean\n\n\n\nString15\nString15\nString15\nFloat64?\nFloat64\nFloat64\n\n\n\n\n1\nJulia\nAccumulator\nnpv9\n6.388\n6.375\n1.0\n\n\n2\nRust\nAccumulator\nnpv3\n7.0\n7.0\n1.09804\n\n\n3\nJulia\nAccumulator\nnpv8\n7.372\n7.375\n1.15686\n\n\n4\nJulia\nAccumulator\nnpv7\n7.92\n7.917\n1.24188\n\n\n5\nJulia\nAccumulator\nnpv6\n9.037\n9.009\n1.41318\n\n\n6\nJulia\nAccumulator\nnpv4\n10.764\n10.761\n1.688\n\n\n7\nJulia\nAccumulator\nnpv5\n11.49\n11.469\n1.79906\n\n\n8\nRust\nAccumulator\nnpv2\n14.0\n14.0\n2.19608\n\n\n9\nJulia\nAccumulator\nnpv3\n14.507\n14.487\n2.27247\n\n\n10\nRust\nAccumulator\nnpv1\n22.0\n22.0\n3.45098\n\n\n11\nJulia\nVectorized\nnpv2\n235.758\n218.391\n34.2574\n\n\n12\nJulia\nVectorized\nnpv1\n235.322\n228.198\n35.7958\n\n\n13\nPython (Numba)\nAccumulator\nnpv_numba\nmissing\n626.0\n98.1961\n\n\n14\nPython\nAccumulator\nnpv_loop\nmissing\n2314.0\n362.98\n\n\n15\nPython (NumPy)\nVectorized\nnpv\nmissing\n14261.0\n2237.02\n\n\n16\nR\nVectorized\nnpv base\n4264.0\n46617.0\n7312.47\n\n\n17\nR\nAccumulator\nnpv_loop\n4346.0\n62275.7\n9768.74\n\n\n18\nR (data.table)\nVectorized\nnpv\n770554.0\n8.42767e5\n1.32199e5\n\n\n\n\n\n\n\n\n\nTo aid in visualizing results with such vast different orders of magnitude, this graph includes a physical length comparison to serve as a reference. The computation time is represented by the distance that light travels in the time for the computation to complete (comparing a nanosecond to one foot length goes at least back to Admiral Grace Hopper).\n\n\n\n\n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nFigure 1\n\n\n\n\n\n\n\nFor more a more in-depth discussion of these results, see this post.\nAll of the benchmarked code can be found in the JuliaActuary Learn repository. Please file an issue or submit a PR request there for issues/suggestions." + "text": "Inspired by the discussion in the ActuarialOpenSource GitHub community discussion, folks started submitted solutions to what someone referred to as the “Life Modeling Problem”. This user submitted a short snippet for consideration of a representative problem.\n\n\nAfter the original user submitted a proposal, others chimed in and submitted versions in their favorite languages. I have collected those versions, and run them on a consistent set of hardware.\nSome submissions were excluded because from the benchmarks they involved an entirely different approach, such as memoizing the function calls[^1].\n\n\n[ Info: Precompiling CSV [336ed68f-0bac-5ca0-87d4-7b16caf5d00b]\n\n\n\n\nTable 1: Benchmarks for the Life Modeling Problem in nanoseconds (lower times are better).\n\n\n\n18×6 DataFrame\n\n\n\nRow\nlang\nalgorithm\nfunction_name\nmedian\nmean\nrelative_mean\n\n\n\nString15\nString15\nString15\nFloat64?\nFloat64\nFloat64\n\n\n\n\n1\nJulia\nAccumulator\nnpv9\n6.388\n6.375\n1.0\n\n\n2\nRust\nAccumulator\nnpv3\n7.0\n7.0\n1.09804\n\n\n3\nJulia\nAccumulator\nnpv8\n7.372\n7.375\n1.15686\n\n\n4\nJulia\nAccumulator\nnpv7\n7.92\n7.917\n1.24188\n\n\n5\nJulia\nAccumulator\nnpv6\n9.037\n9.009\n1.41318\n\n\n6\nJulia\nAccumulator\nnpv4\n10.764\n10.761\n1.688\n\n\n7\nJulia\nAccumulator\nnpv5\n11.49\n11.469\n1.79906\n\n\n8\nRust\nAccumulator\nnpv2\n14.0\n14.0\n2.19608\n\n\n9\nJulia\nAccumulator\nnpv3\n14.507\n14.487\n2.27247\n\n\n10\nRust\nAccumulator\nnpv1\n22.0\n22.0\n3.45098\n\n\n11\nJulia\nVectorized\nnpv2\n235.758\n218.391\n34.2574\n\n\n12\nJulia\nVectorized\nnpv1\n235.322\n228.198\n35.7958\n\n\n13\nPython (Numba)\nAccumulator\nnpv_numba\nmissing\n626.0\n98.1961\n\n\n14\nPython\nAccumulator\nnpv_loop\nmissing\n2314.0\n362.98\n\n\n15\nPython (NumPy)\nVectorized\nnpv\nmissing\n14261.0\n2237.02\n\n\n16\nR\nVectorized\nnpv base\n4264.0\n46617.0\n7312.47\n\n\n17\nR\nAccumulator\nnpv_loop\n4346.0\n62275.7\n9768.74\n\n\n18\nR (data.table)\nVectorized\nnpv\n770554.0\n8.42767e5\n1.32199e5\n\n\n\n\n\n\n\n\n\nTo aid in visualizing results with such vast different orders of magnitude, this graph includes a physical length comparison to serve as a reference. The computation time is represented by the distance that light travels in the time for the computation to complete (comparing a nanosecond to one foot length goes at least back to Admiral Grace Hopper).\n\n\n\n\n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nFigure 1\n\n\n\n\n\n\n\nFor more a more in-depth discussion of these results, see this post.\nAll of the benchmarked code can be found in the JuliaActuary Learn repository. Please file an issue or submit a PR request there for issues/suggestions." }, { "objectID": "benchmarks.html#the-life-modeling-problem", "href": "benchmarks.html#the-life-modeling-problem", "title": "Benchmarks", "section": "", - "text": "Inspired by the discussion in the ActuarialOpenSource GitHub community discussion, folks started submitted solutions to what someone referred to as the “Life Modeling Problem”. This user submitted a short snippet for consideration of a representative problem.\n\n\nAfter the original user submitted a proposal, others chimed in and submitted versions in their favorite languages. I have collected those versions, and run them on a consistent set of hardware.\nSome submissions were excluded because from the benchmarks they involved an entirely different approach, such as memoizing the function calls[^1].\n\n\n\n\nTable 1: Benchmarks for the Life Modeling Problem in nanoseconds (lower times are better).\n\n\n\n18×6 DataFrame\n\n\n\nRow\nlang\nalgorithm\nfunction_name\nmedian\nmean\nrelative_mean\n\n\n\nString15\nString15\nString15\nFloat64?\nFloat64\nFloat64\n\n\n\n\n1\nJulia\nAccumulator\nnpv9\n6.388\n6.375\n1.0\n\n\n2\nRust\nAccumulator\nnpv3\n7.0\n7.0\n1.09804\n\n\n3\nJulia\nAccumulator\nnpv8\n7.372\n7.375\n1.15686\n\n\n4\nJulia\nAccumulator\nnpv7\n7.92\n7.917\n1.24188\n\n\n5\nJulia\nAccumulator\nnpv6\n9.037\n9.009\n1.41318\n\n\n6\nJulia\nAccumulator\nnpv4\n10.764\n10.761\n1.688\n\n\n7\nJulia\nAccumulator\nnpv5\n11.49\n11.469\n1.79906\n\n\n8\nRust\nAccumulator\nnpv2\n14.0\n14.0\n2.19608\n\n\n9\nJulia\nAccumulator\nnpv3\n14.507\n14.487\n2.27247\n\n\n10\nRust\nAccumulator\nnpv1\n22.0\n22.0\n3.45098\n\n\n11\nJulia\nVectorized\nnpv2\n235.758\n218.391\n34.2574\n\n\n12\nJulia\nVectorized\nnpv1\n235.322\n228.198\n35.7958\n\n\n13\nPython (Numba)\nAccumulator\nnpv_numba\nmissing\n626.0\n98.1961\n\n\n14\nPython\nAccumulator\nnpv_loop\nmissing\n2314.0\n362.98\n\n\n15\nPython (NumPy)\nVectorized\nnpv\nmissing\n14261.0\n2237.02\n\n\n16\nR\nVectorized\nnpv base\n4264.0\n46617.0\n7312.47\n\n\n17\nR\nAccumulator\nnpv_loop\n4346.0\n62275.7\n9768.74\n\n\n18\nR (data.table)\nVectorized\nnpv\n770554.0\n8.42767e5\n1.32199e5\n\n\n\n\n\n\n\n\n\nTo aid in visualizing results with such vast different orders of magnitude, this graph includes a physical length comparison to serve as a reference. The computation time is represented by the distance that light travels in the time for the computation to complete (comparing a nanosecond to one foot length goes at least back to Admiral Grace Hopper).\n\n\n\n\n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nFigure 1\n\n\n\n\n\n\n\nFor more a more in-depth discussion of these results, see this post.\nAll of the benchmarked code can be found in the JuliaActuary Learn repository. Please file an issue or submit a PR request there for issues/suggestions." + "text": "Inspired by the discussion in the ActuarialOpenSource GitHub community discussion, folks started submitted solutions to what someone referred to as the “Life Modeling Problem”. This user submitted a short snippet for consideration of a representative problem.\n\n\nAfter the original user submitted a proposal, others chimed in and submitted versions in their favorite languages. I have collected those versions, and run them on a consistent set of hardware.\nSome submissions were excluded because from the benchmarks they involved an entirely different approach, such as memoizing the function calls[^1].\n\n\n[ Info: Precompiling CSV [336ed68f-0bac-5ca0-87d4-7b16caf5d00b]\n\n\n\n\nTable 1: Benchmarks for the Life Modeling Problem in nanoseconds (lower times are better).\n\n\n\n18×6 DataFrame\n\n\n\nRow\nlang\nalgorithm\nfunction_name\nmedian\nmean\nrelative_mean\n\n\n\nString15\nString15\nString15\nFloat64?\nFloat64\nFloat64\n\n\n\n\n1\nJulia\nAccumulator\nnpv9\n6.388\n6.375\n1.0\n\n\n2\nRust\nAccumulator\nnpv3\n7.0\n7.0\n1.09804\n\n\n3\nJulia\nAccumulator\nnpv8\n7.372\n7.375\n1.15686\n\n\n4\nJulia\nAccumulator\nnpv7\n7.92\n7.917\n1.24188\n\n\n5\nJulia\nAccumulator\nnpv6\n9.037\n9.009\n1.41318\n\n\n6\nJulia\nAccumulator\nnpv4\n10.764\n10.761\n1.688\n\n\n7\nJulia\nAccumulator\nnpv5\n11.49\n11.469\n1.79906\n\n\n8\nRust\nAccumulator\nnpv2\n14.0\n14.0\n2.19608\n\n\n9\nJulia\nAccumulator\nnpv3\n14.507\n14.487\n2.27247\n\n\n10\nRust\nAccumulator\nnpv1\n22.0\n22.0\n3.45098\n\n\n11\nJulia\nVectorized\nnpv2\n235.758\n218.391\n34.2574\n\n\n12\nJulia\nVectorized\nnpv1\n235.322\n228.198\n35.7958\n\n\n13\nPython (Numba)\nAccumulator\nnpv_numba\nmissing\n626.0\n98.1961\n\n\n14\nPython\nAccumulator\nnpv_loop\nmissing\n2314.0\n362.98\n\n\n15\nPython (NumPy)\nVectorized\nnpv\nmissing\n14261.0\n2237.02\n\n\n16\nR\nVectorized\nnpv base\n4264.0\n46617.0\n7312.47\n\n\n17\nR\nAccumulator\nnpv_loop\n4346.0\n62275.7\n9768.74\n\n\n18\nR (data.table)\nVectorized\nnpv\n770554.0\n8.42767e5\n1.32199e5\n\n\n\n\n\n\n\n\n\nTo aid in visualizing results with such vast different orders of magnitude, this graph includes a physical length comparison to serve as a reference. The computation time is represented by the distance that light travels in the time for the computation to complete (comparing a nanosecond to one foot length goes at least back to Admiral Grace Hopper).\n\n\n\n\n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n \n \n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nFigure 1\n\n\n\n\n\n\n\nFor more a more in-depth discussion of these results, see this post.\nAll of the benchmarked code can be found in the JuliaActuary Learn repository. Please file an issue or submit a PR request there for issues/suggestions." }, { "objectID": "benchmarks.html#irrs", diff --git a/sitemap.xml b/sitemap.xml index e99eed3..34edc26 100644 --- a/sitemap.xml +++ b/sitemap.xml @@ -2,122 +2,122 @@ https://JuliaActuary.org/blog.html - 2024-06-17T03:29:44.486Z + 2024-06-18T03:39:01.368Z https://JuliaActuary.org/packages.html - 2024-06-17T02:46:38.178Z + 2024-06-18T03:39:01.368Z https://JuliaActuary.org/index.html - 2024-06-17T02:46:11.253Z + 2024-06-18T03:39:01.368Z https://JuliaActuary.org/posts/mortality-comparison/index.html - 2024-06-16T21:18:09.490Z + 2024-06-18T03:39:01.377Z https://JuliaActuary.org/posts/exposures-example/index.html - 2024-06-16T01:50:06.671Z + 2024-06-18T03:39:01.374Z https://JuliaActuary.org/posts/stochastic-mortality/index.html - 2024-06-15T16:35:16.344Z + 2024-06-18T03:39:01.378Z https://JuliaActuary.org/posts/academy-generator-rates/index.html - 2024-06-16T15:00:16.040Z + 2024-06-18T03:39:01.371Z https://JuliaActuary.org/posts/hacktoberfest/index.html - 2024-06-17T02:54:36.846Z + 2024-06-18T03:39:01.375Z https://JuliaActuary.org/posts/bayes-vs-limited-fluctuation/index.html - 2024-06-16T21:41:41.288Z + 2024-06-18T03:39:01.371Z https://JuliaActuary.org/posts/mortalitytables-and-dataframes/index.html - 2024-06-15T15:41:27.430Z + 2024-06-18T03:39:01.377Z https://JuliaActuary.org/posts/nested-policy-projections/index.html - 2024-06-16T03:16:59.653Z + 2024-06-18T03:39:01.377Z https://JuliaActuary.org/posts/bayesian-claims-demo/index.html - 2024-06-16T02:18:48.900Z + 2024-06-18T03:39:01.372Z https://JuliaActuary.org/posts/treasury-interactive/index.html - 2024-06-16T13:52:06.076Z + 2024-06-18T03:39:01.378Z https://JuliaActuary.org/posts/cashflow-interactive/index.html - 2024-06-16T15:00:44.501Z + 2024-06-18T03:39:01.373Z https://JuliaActuary.org/examples.html - 2024-06-17T02:57:30.830Z + 2024-06-18T03:39:01.368Z https://JuliaActuary.org/community.html - 2024-06-17T02:59:26.307Z + 2024-06-18T03:39:01.368Z https://JuliaActuary.org/posts/finance-models-announcement/index.html - 2024-06-17T02:54:26.033Z + 2024-06-18T03:39:01.374Z https://JuliaActuary.org/posts/policy-diffeq/index.html - 2024-06-17T01:50:58.498Z + 2024-06-18T03:39:01.378Z https://JuliaActuary.org/posts/life-modeling-problem/index.html - 2024-06-17T02:54:48.784Z + 2024-06-18T03:39:01.375Z https://JuliaActuary.org/posts/bayesian-intro/index.html - 2024-06-17T02:54:18.391Z + 2024-06-18T03:39:01.372Z https://JuliaActuary.org/posts/julia-for-actuaries/index.html - 2024-06-17T02:54:42.670Z + 2024-06-18T03:39:01.375Z https://JuliaActuary.org/posts/poisson-approximation/index.html - 2024-06-16T21:17:53.237Z + 2024-06-18T03:39:01.378Z https://JuliaActuary.org/posts/fitting-yield-curves/index.html - 2024-06-16T03:16:08.017Z + 2024-06-18T03:39:01.374Z https://JuliaActuary.org/posts/fitting-survival-data/index.html - 2024-06-15T16:08:37.185Z + 2024-06-18T03:39:01.374Z https://JuliaActuary.org/posts/getting-started-for-actuaries/index.html - 2024-06-17T02:54:32.086Z + 2024-06-18T03:39:01.375Z https://JuliaActuary.org/posts/coding-the-future/index.html - 2024-06-17T02:54:10.385Z + 2024-06-18T03:39:01.374Z https://JuliaActuary.org/posts/academy-generator/index.html - 2024-06-16T14:45:08.569Z + 2024-06-18T03:39:01.371Z https://JuliaActuary.org/benchmarks.html - 2024-06-15T13:32:36.848Z + 2024-06-18T03:39:01.368Z https://JuliaActuary.org/all-posts.html - 2024-06-17T03:35:46.509Z + 2024-06-18T03:39:01.322Z https://JuliaActuary.org/learn.html - 2024-06-17T02:48:31.135Z + 2024-06-18T03:39:01.368Z diff --git a/styles.css b/styles.css index c2e578f..74bb4b9 100644 --- a/styles.css +++ b/styles.css @@ -122,6 +122,12 @@ pre { font-weight: 400; } +@media (max-width: 800px) { + .hero-grid { + flex-direction: column; + } +} + .hero-child { flex: 1; }