diff --git a/docs/Project.toml b/docs/Project.toml index 24ca5f6..8e8e4cb 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -1,3 +1,5 @@ [deps] Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" +DocumenterCitations = "daee34ce-89f3-4625-b898-19384cb65244" +LiveServer = "16fef848-5104-11e9-1b77-fb7a48bbb589" NetSurvival = "8f9d5d0e-dd2e-4568-92d4-f8c5d34f25cf" diff --git a/docs/make.jl b/docs/make.jl index 1cf19a6..b644d00 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -1,10 +1,17 @@ using NetSurvival using Documenter +using DocumenterCitations DocMeta.setdocmeta!(NetSurvival, :DocTestSetup, :(using NetSurvival); recursive=true) +bib = CitationBibliography( + joinpath(@__DIR__,"src","assets","references.bib"), + style=:numeric +) + makedocs(; modules=[NetSurvival], + plugins=[bib], authors="Oskar Laverny and contributors", sitename="NetSurvival.jl", format=Documenter.HTML(; diff --git a/docs/src/assets/references.bib b/docs/src/assets/references.bib new file mode 100644 index 0000000..49a2dbe --- /dev/null +++ b/docs/src/assets/references.bib @@ -0,0 +1,10 @@ +@article{PoharPerme2012, + title={On estimation in relative survival}, + author={Perme, Maja Pohar and Stare, Janez and Est{\`e}ve, Jacques}, + journal={Biometrics}, + volume={68}, + number={1}, + pages={113--120}, + year={2012}, + publisher={Oxford University Press} +} \ No newline at end of file diff --git a/docs/src/index.md b/docs/src/index.md index 6c30a14..8b9a295 100644 --- a/docs/src/index.md +++ b/docs/src/index.md @@ -6,9 +6,15 @@ CurrentModule = NetSurvival Documentation for [NetSurvival](https://github.com/JuliaSurv/NetSurvival.jl). +This is an example reference : [PoharPerme2012](@cite). + + ```@index ``` ```@autodocs Modules = [NetSurvival] ``` + +```@bibliography +```