Package: BetaDanish 1.0.0

BetaDanish: The Beta-Danish Distribution for Lifetime Data Analysis

Implements the four-parameter Beta-Danish distribution and its three-parameter Exponentiated Danish submodel for survival, reliability and lifetime data analysis, following Ahmad (2026), "Modeling Diverse Survival Patterns: The Development and Characterization of a New Four-Parameter Lifetime Distribution", PhD thesis, Allama Iqbal Open University. Density, distribution, quantile, survival, hazard and random generation functions are evaluated so as to retain accuracy in both tails; the upper tail is heavy, with a regularly varying survival function. Estimation covers maximum likelihood for complete and right-censored samples by a two-stage multi-start search that guarantees nesting of the submodel, with fits on the edge of the parameter space reported as such, ridge-penalized fitting for weakly identified regimes, a grouped likelihood for times recorded on a coarse grid, and Bayesian sampling by adaptive multi-chain Metropolis with convergence checks. Goodness of fit uses Kolmogorov-Smirnov, Cramer-von Mises and Anderson-Darling statistics computed on one scale for complete and censored samples. Inference provides log-scale Wald and profile likelihood intervals, together with a reparameterization in terms of the identified composite of the two shape parameters. Structural properties include raw, incomplete and conditional moments with their existence conditions, Shannon, Renyi and Tsallis entropies, mean residual life, mean deviations, Lorenz and Bonferroni curves, probability weighted moments, order statistics, stress-strength reliability, hazard shape classification, the tail index and the Kullback-Leibler separation from the submodel. Regression modules cover accelerated failure time models, mixture and promotion-time cure models with three- or four-parameter kernels, and competing risks with Aalen-Johansen comparison and Gray's test. Analyses can be run directly from a delimited text file or spreadsheet.

Authors:Bilal Ahmad [aut, cre], Muhammad Yameen Danish [aut]

BetaDanish_1.0.0.tar.gz
BetaDanish_1.0.0.zip(r-4.7-any)BetaDanish_1.0.0.zip(r-4.6-any)BetaDanish_1.0.0.zip(r-4.5-any)
BetaDanish_1.0.0.tgz(r-4.6-any)BetaDanish_1.0.0.tgz(r-4.5-any)
BetaDanish_1.0.0.tar.gz(r-4.7-any)BetaDanish_1.0.0.tar.gz(r-4.6-any)
BetaDanish_1.0.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html✨
DESCRIPTION |NEWS
card.svg |card.png
BetaDanish/json (API)

# Install 'BetaDanish' in R:
install.packages('BetaDanish', repos = c('https://bilal-aiou.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/bilal-aiou/betadanish/issues

Pkgdown/docs site:https://bilal-aiou.github.io

Datasets:

On CRAN:

Conda:

5.08 score 295 downloads 58 exports 9 dependencies

Last updated from:2525d8d11d. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-develOK213
source / vignettesOK196
linux-releaseOK201
macos-releaseOK143
macos-oldrelOK140
windows-develOK177
windows-releaseOK238
windows-oldrelOK176
wasm-releaseOK120

Exports:analyze_betadanishbayes_betadanishbd_analyze_csvbd_bonferronibd_conditional_momentbd_csv_templatebd_entropy_renyibd_entropy_shannonbd_entropy_tsallisbd_hazard_shapebd_identified_coefbd_incomplete_momentbd_kl_submodelbd_lorenzbd_mean_deviationbd_moment_summarybd_momentsbd_mrlbd_order_stat_cdfbd_order_stat_momentsbd_order_stat_pdfbd_profile_cibd_profile_plotbd_pwmbd_rmrlbd_simulation_competingbd_simulation_curebd_simulation_studybd_stress_strengthbd_tail_indexbd_ttt_plotbd_wald_cicif_betadanishcif_comparecompare_distributionscompare_modelsdbetadanishdedfit_bd_aftfit_bd_competingfit_bd_curefit_betadanishgof_betadanishhbetadanishhedpbetadanishpedqbetadanishqedrbetadanishread_survival_dataredreport_betadanishsbetadanishsedsimulate_bd_competing_datasimulate_bd_cure_datasimulate_bd_data

Dependencies:digestgenericslatticeMatrixmaxLikmiscToolssandwichsurvivalzoo

Bayesian Estimation with BetaDanish
1. Overview | 2. ED submodel on bladder cancer remission times | 3. Posterior diagnostics | 4. Posterior survival vs Kaplan-Meier | 5. Bayesian vs MLE comparison | 6. The four-parameter model

Last update: 2026-11-13
Started: 2026-06-03

Competing Risks with the Beta-Danish Distribution
Overview | Simulated two-cause data | Fitting the model | CIF comparison: Beta-Danish vs Aalen-Johansen | Gray's test | Covariates (new in 0.3.0) | A caution worth repeating

Last update: 2026-07-31
Started: 2026-06-03

Introduction to the BetaDanish Package
1. Introduction | 2. Theoretical Background | The 3-Parameter Submodel | 3. Core Distribution Functions | 4. Fitting Models to Data | Example 1: Uncensored Data (Bladder Cancer Remission) | Example 2: Right-Censored Data (Bone Marrow Transplant) | 5. Advanced Modeling: Cure Rates | 6. Automated Benchmarking | 7. Conclusion | New in 0.3.0 | Structural properties | Shape, before and after fitting | Interval estimation | Simulation studies

Last update: 2026-07-31
Started: 2026-05-11

Analysing Your Own Data from a CSV File
What the file should look like | Reading a file | A word on censor | One-call analysis | Comparing the parent model against its submodel | Saving tables and figures | Regression from a file | When something fails

Last update: 2026-07-30
Started: 2026-07-30

Cure Models with the Beta-Danish Distribution
Two cure formulations | Quick example | Mixture cure model | Promotion-time cure model | See also

Last update: 2026-06-03
Started: 2026-06-03

A Case Study Using the Beta-Danish Distribution
Introduction | Fitting the Beta-Danish model | Three-parameter submodel | Diagnostic plots | Interpretation

Last update: 2026-05-11
Started: 2026-05-11

Readme and manuals

Help Manual

Help pageTopics
Aarset Device Failure Timesaarset
Comprehensive Beta-Danish Analysis Pipelineanalyze_betadanish
Bayesian Estimation for the Beta-Danish Distributionbayes_betadanish
Analyse Survival Data Straight from a CSV Filebd_analyze_csv plot.bd_analysis print.bd_analysis print.summary.bd_analysis summary.bd_analysis
Conditional Momentsbd_conditional_moment
Write a Skeleton CSV for BetaDanishbd_csv_template
Entropies of the Beta-Danish Distributionbd_entropy bd_entropy_renyi bd_entropy_shannon bd_entropy_tsallis
Hazard Rate Shape and the Glaser Diagnosticbd_hazard_shape print.bd_shape
Coefficients in the Identified Parametrisationbd_identified_coef print.bd_identified
Incomplete Momentsbd_incomplete_moment
Kullback-Leibler Separation from the Exponentiated Danish Submodelbd_kl_submodel
Lorenz and Bonferroni Curvesbd_bonferroni bd_lorenz
Mean Deviationsbd_mean_deviation
Summary Moments: Mean, Variance, Skewness and Kurtosisbd_moment_summary
Raw Moments of the Beta-Danish Distributionbd_moments
Mean Residual Life and Reversed Mean Residual Lifebd_mrl bd_rmrl
Order Statistic Distribution and Momentsbd_order_stat_cdf bd_order_stat_moments
Density of the r-th Order Statisticbd_order_stat_pdf
Profile Likelihood Confidence Intervalbd_profile_ci print.bd_profile
Plot a Profile Likelihoodbd_profile_plot
Probability Weighted Momentsbd_pwm
Finite-Sample Simulation Study for Competing Risksbd_simulation_competing
Finite-Sample Simulation Study for the Cure Modelbd_simulation_cure
Finite-Sample Simulation Study for the Univariate Modelbd_simulation_study print.bd_simulation summary.bd_simulation
Stress-Strength Reliabilitybd_stress_strength
Tail Index of the Beta-Danish Distributionbd_tail_index
Scaled Total Time on Test Plotbd_ttt_plot
Log-Scale Wald Confidence Intervalsbd_wald_ci
The Beta-Danish DistributionBetaDanish dbetadanish hbetadanish pbetadanish qbetadanish rbetadanish sbetadanish
Breaking Stress of Carbon Fibrescarbon_fibres
Cumulative Incidence Functioncif_betadanish
Compare Model-Based CIF to the Aalen-Johansen Estimatorcif_compare
Extract Coefficientscoef.betadanish
Compare Beta-Danish with Standard Distributionscompare_distributions
Compare Nested Beta-Danish Modelscompare_models
The Exponentiated Danish Distributionded ExponentiatedDanish hed ped qed red sed
Fit Beta-Danish AFT Regression Modelfit_bd_aft
Fit a Beta-Danish Competing Risks Modelfit_bd_competing
Fit Beta-Danish Cure Modelsfit_bd_cure
Fit the Beta-Danish Distribution to Survival Datafit_betadanish
Goodness-of-Fit Statistics for Beta-Danish Modelsgof_betadanish
Guinea Pig Survival Timesguinea_pig
Acute Myelogenous Leukemia Survivalleukemia
Extract Log-LikelihoodlogLik.betadanish
Malignant Melanoma Survival After Surgerymelanoma
Cox-Snell Residual Plot for AFT and Cure Fitsplot.bd_aft plot.bd_cure
Diagnostic Plots for a Bayesian Fitplot.bd_bayes
Plot Diagnostics for Beta-Danish Fitplot.betadanish
Print Method for Beta-Danish Fitprint.betadanish
Print Summary Method for Beta-Danish Fitprint.summary.betadanish
Read and Prepare Survival Dataread_survival_data
Bladder Cancer Remission Timesremission
Create a Compact Report from a Beta-Danish Model Fitprint.betadanish_report report_betadanish
Simulate Competing Risks Datasimulate_bd_competing_data
Simulate Beta-Danish Cure Datasimulate_bd_cure_data
Simulate Data from the Beta-Danish Distributionsimulate_bd_data
Summary Method for Beta-Danish Fitsummary.betadanish
Bone Marrow Transplant Survivaltransplant
Extract Variance-Covariance Matrixvcov.betadanish