{
  "_id": "6a3572b03efcd9bda43ebb02",
  "Package": "kofn",
  "Title": "Maximum Likelihood Estimation for k-Out-of-n System Data",
  "Version": "0.4.0",
  "Authors@R": "person(\"Alexander\", \"Towell\",\nemail = \"lex@metafunctor.com\",\nrole = c(\"aut\", \"cre\"),\ncomment = c(ORCID = \"0000-0001-6443-9897\"))",
  "Description": "Maximum likelihood estimation of component lifetime\nparameters from system-level observations of k-out-of-n\nsystems. Supports exponential and Weibull component\ndistributions under multiple observation schemes: Scheme 0\n(system lifetime only), Scheme 1 (periodic inspection), and\nScheme 2 (complete monitoring). Provides an EM algorithm for\nWeibull parallel systems and Fisher information comparison\nacross schemes. The k-out-of-n framework unifies series (k=1)\nand parallel (k=m) systems as a censoring problem on component\nlifetimes. Conforms to the 'likelihood.model' generics and\nreturns fitted objects compatible with 'algebraic.mle'. The\ndata-generating process and topology infrastructure (system\nsurvival, density, signature, structure function, importance\nmeasures) are delegated to the 'dist.structure' package; 'kofn'\nfocuses exclusively on inference for the k-out-of-n family.",
  "License": "MIT + file LICENSE",
  "URL": "https://github.com/queelius/kofn, https://queelius.github.io/kofn/",
  "BugReports": "https://github.com/queelius/kofn/issues",
  "Config/testthat/edition": "3",
  "Encoding": "UTF-8",
  "RoxygenNote": "7.3.3",
  "VignetteBuilder": "knitr",
  "NeedsCompilation": "no",
  "Packaged": {
    "Date": "2026-06-19 16:44:12 UTC",
    "User": "root"
  },
  "Author": "Alexander Towell [aut, cre] (ORCID:\n<https://orcid.org/0000-0001-6443-9897>)",
  "Maintainer": "Alexander Towell <lex@metafunctor.com>",
  "Repository": "https://cran.r-universe.dev",
  "Date/Publication": "2026-06-19 12:00:29 UTC",
  "RemoteUrl": "https://github.com/cran/kofn",
  "RemoteRef": "HEAD",
  "RemoteSha": "74039558aa6fb5ceb59730184f6183d822c78f25",
  "MD5sum": "910f165aecbd4af814bcab093899aa1d",
  "_user": "cran",
  "_type": "src",
  "_file": "kofn_0.4.0.tar.gz",
  "_fileid": "1ab40108f65048515f3bd28f00f4fc53df4204cdd78f1faa55596ff0902ebe97",
  "_filesize": 1322015,
  "_sha256": "1ab40108f65048515f3bd28f00f4fc53df4204cdd78f1faa55596ff0902ebe97",
  "_created": "2026-06-19T16:44:12.000Z",
  "_published": "2026-06-19T16:47:44.551Z",
  "_distro": "noble",
  "_jobs": [
    {
      "job": 82390426133,
      "time": 180,
      "config": "linux-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "7754732331"
    },
    {
      "job": 82390426367,
      "time": 180,
      "config": "linux-release-x86_64",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7754732623"
    },
    {
      "job": 82389731544,
      "time": 317,
      "config": "source",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7754685734"
    },
    {
      "job": 82390426105,
      "time": 105,
      "config": "wasm-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7754713175"
    }
  ],
  "_buildurl": "https://github.com/r-universe/cran/actions/runs/27837770872",
  "_status": "success",
  "_host": "GitHub-Actions",
  "_upstream": "https://github.com/cran/kofn",
  "_commit": {
    "id": "74039558aa6fb5ceb59730184f6183d822c78f25",
    "author": "Alexander Towell <lex@metafunctor.com>",
    "committer": "cran-robot <csardi.gabor+cran@gmail.com>",
    "message": "version 0.4.0\n",
    "time": 1781870429
  },
  "_maintainer": {
    "name": "Alexander Towell",
    "email": "lex@metafunctor.com",
    "login": "queelius",
    "orcid": "0000-0001-6443-9897",
    "twitter": "@queelius",
    "description": "Alexander Towell (Alex Towell). Reliability theory, encrypted search, algebraic structures. Building personal data tools.",
    "uuid": 1896674
  },
  "_registered": true,
  "_dependencies": [
    {
      "package": "R",
      "version": ">= 4.1.0",
      "role": "Depends"
    },
    {
      "package": "stats",
      "role": "Imports"
    },
    {
      "package": "numDeriv",
      "role": "Imports"
    },
    {
      "package": "likelihood.model",
      "role": "Imports"
    },
    {
      "package": "compositional.mle",
      "role": "Imports"
    },
    {
      "package": "generics",
      "role": "Imports"
    },
    {
      "package": "dist.structure",
      "role": "Imports"
    },
    {
      "package": "algebraic.dist",
      "role": "Imports"
    },
    {
      "package": "flexhaz",
      "version": ">= 0.5.2",
      "role": "Imports"
    },
    {
      "package": "algebraic.mle",
      "role": "Suggests"
    },
    {
      "package": "maskedcauses",
      "role": "Suggests"
    },
    {
      "package": "testthat",
      "version": ">= 3.0.0",
      "role": "Suggests"
    },
    {
      "package": "knitr",
      "role": "Suggests"
    },
    {
      "package": "rmarkdown",
      "role": "Suggests"
    }
  ],
  "_owner": "cran",
  "_selfowned": false,
  "_usedby": 0,
  "_updates": [
    {
      "week": "2026-25",
      "n": 1
    }
  ],
  "_tags": [
    {
      "name": "0.4.0",
      "date": "2026-06-19"
    }
  ],
  "_stars": 0,
  "_contributors": [
    {
      "user": "queelius",
      "count": 1,
      "uuid": 1896674
    }
  ],
  "_userbio": {
    "uuid": 6899542,
    "type": "organization",
    "name": "cran",
    "followers": 610,
    "description": "Unofficial read-only mirror of all CRAN R packages"
  },
  "_downloads": {
    "count": 0,
    "source": "https://cranlogs.r-pkg.org/downloads/total/last-month/kofn"
  },
  "_devurl": "https://github.com/queelius/kofn",
  "_pkgdown": "https://queelius.github.io/kofn/",
  "_searchresults": 9,
  "_rbuild": "4.6.0",
  "_assets": [
    "extra/citation.cff",
    "extra/citation.html",
    "extra/citation.json",
    "extra/citation.txt",
    "extra/contents.json",
    "extra/kofn.html",
    "extra/NEWS.html",
    "extra/NEWS.txt",
    "extra/readme.html",
    "extra/readme.md",
    "LICENSE",
    "manual.pdf"
  ],
  "_cranurl": false,
  "_releases": [
    {
      "version": "0.4.0",
      "date": "2026-06-19"
    }
  ],
  "_exports": [
    "assumptions",
    "compare_fisher_info",
    "dfr_exponential",
    "dfr_weibull",
    "F_sys_exp",
    "fit",
    "fit_scheme1",
    "hess_loglik",
    "ie_expand",
    "is_kofn",
    "kofn",
    "loglik",
    "loglik_masked",
    "loglik_scheme1",
    "ncomponents",
    "observe_exact",
    "observe_interval_censor",
    "observe_left_censor",
    "observe_mixture",
    "observe_periodic",
    "observe_right_censor",
    "rdata",
    "rdata_masked",
    "rdata_scheme1",
    "S_sys_exp",
    "score",
    "solve_mle",
    "trunc_log_moment_vec",
    "trunc_pow_moment",
    "trunc_pow_moment_vec",
    "w_j_exact",
    "w_j_integral"
  ],
  "_help": [
    {
      "page": "assumptions.exp_kofn",
      "title": "Assumptions for exponential k-out-of-n model",
      "topics": [
        "assumptions.exp_kofn"
      ]
    },
    {
      "page": "assumptions.wei_kofn",
      "title": "Assumptions for Weibull k-out-of-n system model",
      "topics": [
        "assumptions.wei_kofn"
      ]
    },
    {
      "page": "compare_fisher_info",
      "title": "Compare Fisher information across observation schemes",
      "topics": [
        "compare_fisher_info"
      ]
    },
    {
      "page": "F_sys_exp",
      "title": "System CDF for exponential parallel systems",
      "topics": [
        "F_sys_exp"
      ]
    },
    {
      "page": "fit_scheme1",
      "title": "Fit k-out-of-n system MLE under Scheme 1 (periodic inspection)",
      "topics": [
        "fit_scheme1"
      ]
    },
    {
      "page": "fit.exp_kofn",
      "title": "MLE fitting for exponential k-out-of-n model",
      "topics": [
        "fit.exp_kofn"
      ]
    },
    {
      "page": "fit.wei_kofn",
      "title": "Fit Weibull k-out-of-n system model",
      "topics": [
        "fit.wei_kofn"
      ]
    },
    {
      "page": "hess_loglik.exp_kofn",
      "title": "Hessian of the log-likelihood for exponential k-out-of-n model",
      "topics": [
        "hess_loglik.exp_kofn"
      ]
    },
    {
      "page": "hess_loglik.wei_kofn",
      "title": "Hessian of log-likelihood for Weibull k-out-of-n system",
      "topics": [
        "hess_loglik.wei_kofn"
      ]
    },
    {
      "page": "ie_expand",
      "title": "Inclusion-exclusion expansion of a product of CDFs",
      "topics": [
        "ie_expand"
      ]
    },
    {
      "page": "is_kofn",
      "title": "Test if an object is a kofn model",
      "topics": [
        "is_kofn"
      ]
    },
    {
      "page": "kofn",
      "title": "Create a k-out-of-n system estimation model",
      "topics": [
        "kofn"
      ]
    },
    {
      "page": "loglik_masked",
      "title": "Masked k-out-of-n log-likelihood",
      "topics": [
        "loglik_masked"
      ]
    },
    {
      "page": "loglik_scheme1",
      "title": "Log-likelihood for Scheme 1 (periodic inspection) parallel system",
      "topics": [
        "loglik_scheme1"
      ]
    },
    {
      "page": "loglik.exp_kofn",
      "title": "Log-likelihood for exponential k-out-of-n model",
      "topics": [
        "loglik.exp_kofn"
      ]
    },
    {
      "page": "loglik.wei_kofn",
      "title": "Log-likelihood for Weibull k-out-of-n system",
      "topics": [
        "loglik.wei_kofn"
      ]
    },
    {
      "page": "ncomponents.kofn",
      "title": "Number of components in a kofn model",
      "topics": [
        "ncomponents.kofn"
      ]
    },
    {
      "page": "observe_exact",
      "title": "Exact observation scheme (no censoring)",
      "topics": [
        "observe_exact"
      ]
    },
    {
      "page": "observe_interval_censor",
      "title": "Interval-censoring observation scheme",
      "topics": [
        "observe_interval_censor"
      ]
    },
    {
      "page": "observe_left_censor",
      "title": "Left-censoring observation scheme",
      "topics": [
        "observe_left_censor"
      ]
    },
    {
      "page": "observe_mixture",
      "title": "Mixture of observation schemes",
      "topics": [
        "observe_mixture"
      ]
    },
    {
      "page": "observe_periodic",
      "title": "Periodic inspection observation scheme",
      "topics": [
        "observe_periodic"
      ]
    },
    {
      "page": "observe_right_censor",
      "title": "Right-censoring observation scheme",
      "topics": [
        "observe_right_censor"
      ]
    },
    {
      "page": "print.kofn",
      "title": "Print method for kofn models",
      "topics": [
        "print.kofn"
      ]
    },
    {
      "page": "rdata_masked",
      "title": "Generate masked k-out-of-n data",
      "topics": [
        "rdata_masked"
      ]
    },
    {
      "page": "rdata_scheme1",
      "title": "Generate Scheme 1 (periodic inspection) data",
      "topics": [
        "rdata_scheme1"
      ]
    },
    {
      "page": "rdata.exp_kofn",
      "title": "Random data generation for exponential k-out-of-n model",
      "topics": [
        "rdata.exp_kofn"
      ]
    },
    {
      "page": "rdata.wei_kofn",
      "title": "Generate random data from a Weibull k-out-of-n system",
      "topics": [
        "rdata.wei_kofn"
      ]
    },
    {
      "page": "S_sys_exp",
      "title": "System survival function for exponential parallel systems",
      "topics": [
        "S_sys_exp"
      ]
    },
    {
      "page": "score.exp_kofn",
      "title": "Score function for exponential k-out-of-n model",
      "topics": [
        "score.exp_kofn"
      ]
    },
    {
      "page": "score.wei_kofn",
      "title": "Score function for Weibull k-out-of-n system",
      "topics": [
        "score.wei_kofn"
      ]
    },
    {
      "page": "solve_mle",
      "title": "Default MLE solver for positive parameters",
      "topics": [
        "solve_mle"
      ]
    },
    {
      "page": "trunc_log_moment_vec",
      "title": "Vectorized truncated log-moment of the Weibull distribution",
      "topics": [
        "trunc_log_moment_vec"
      ]
    },
    {
      "page": "trunc_pow_moment",
      "title": "Scalar truncated power moment of the Weibull distribution",
      "topics": [
        "trunc_pow_moment"
      ]
    },
    {
      "page": "trunc_pow_moment_vec",
      "title": "Vectorized truncated power moment of the Weibull distribution",
      "topics": [
        "trunc_pow_moment_vec"
      ]
    },
    {
      "page": "w_j_exact",
      "title": "Component weight for exponential parallel systems",
      "topics": [
        "w_j_exact"
      ]
    },
    {
      "page": "w_j_integral",
      "title": "Closed-form integral of w_j(t) over an interval",
      "topics": [
        "w_j_integral"
      ]
    }
  ],
  "_readme": "https://github.com/cran/kofn/raw/HEAD/README.md",
  "_rundeps": [
    "algebraic.dist",
    "algebraic.mle",
    "boot",
    "compositional.mle",
    "dist.structure",
    "flexhaz",
    "generics",
    "likelihood.model",
    "MASS",
    "mvtnorm",
    "numDeriv",
    "R6"
  ],
  "_vignettes": [
    {
      "source": "dist-structure-integration.Rmd",
      "filename": "dist-structure-integration.html",
      "title": "dist.structure integration",
      "engine": "knitr::rmarkdown",
      "headings": [
        "Two packages, two missions",
        "What kofn delegates to dist.structure",
        "When you might invoke dist.structure directly",
        "Convention conversion",
        "Migration notes: v0.2.0 -> v0.3.0",
        "Why this architecture"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    },
    {
      "source": "exponential-parallel.Rmd",
      "filename": "exponential-parallel.html",
      "title": "Exponential Parallel Systems: Closed-Form MLE via Inclusion-Exclusion",
      "engine": "knitr::rmarkdown",
      "headings": [
        "The Exponential Parallel System",
        "Inclusion-Exclusion Expansion",
        "Likelihood Under Different Observation Types",
        "Maximum Likelihood Estimation",
        "Data generation",
        "Fitting",
        "Comparison with true values",
        "Permutation Symmetry",
        "Monte Carlo Validation",
        "Results",
        "Observation Functors",
        "Scheme 0: System lifetime with right-censoring",
        "Effect of censoring on estimation",
        "Scheme 1: Periodic inspection"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    },
    {
      "source": "getting-started.Rmd",
      "filename": "getting-started.html",
      "title": "Getting started with kofn",
      "engine": "knitr::rmarkdown",
      "headings": [
        "What kofn does",
        "Your first fit",
        "Convention",
        "Observation schemes",
        "Weibull components",
        "Periodic inspection (Scheme 1)",
        "Masked cause-of-failure",
        "Fisher information comparison",
        "What's next"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    },
    {
      "source": "ecosystem.Rmd",
      "filename": "ecosystem.html",
      "title": "Inside kofn: Building on the rlang MLE Stack",
      "engine": "knitr::rmarkdown",
      "headings": [
        "The design in one paragraph",
        "The stack",
        "A running example",
        "Layer 1: the likelihood calculus (likelihood.model)",
        "Layer 2: the optimizer (compositional.mle)",
        "Layer 3: the MLE object (algebraic.mle)",
        "Layer 4: the distribution bridge (algebraic.dist)",
        "What had to be specialized",
        "Extending the stack",
        "Further reading"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    },
    {
      "source": "observation-schemes.Rmd",
      "filename": "observation-schemes.html",
      "title": "Observation Scheme Composability",
      "engine": "knitr::rmarkdown",
      "headings": [
        "The Observe Functor API",
        "Composing Schemes with rdata",
        "Effect on Estimation",
        "Mixed Observation Environments"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    },
    {
      "source": "periodic-inspection.Rmd",
      "filename": "periodic-inspection.html",
      "title": "Observation Schemes: Resolving Information Asymmetry via Periodic Inspection",
      "engine": "knitr::rmarkdown",
      "headings": [
        "Introduction",
        "1. The observation scheme hierarchy",
        "2. The information asymmetry problem",
        "3. Scheme 1: Periodic inspection",
        "The likelihood",
        "4. Scheme 0 vs Scheme 1 comparison",
        "Monte Carlo comparison",
        "5. Sensitivity to inspection interval width",
        "6. Information-theoretic interpretation",
        "7. Fisher information comparison",
        "8. Scheme 1 across the k-spectrum",
        "9. Practical guidelines"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    },
    {
      "source": "weibull-em.Rmd",
      "filename": "weibull-em.html",
      "title": "Weibull Parallel Systems: EM Algorithm for Shape-Scale Estimation",
      "engine": "knitr::rmarkdown",
      "headings": [
        "Why Weibull?",
        "What breaks: from exponential to Weibull",
        "Direct MLE struggles",
        "The EM algorithm",
        "E-step: classification and truncated moments",
        "M-step: profile optimization",
        "EM vs direct MLE comparison",
        "Shape effect on estimation difficulty",
        "Mixed shapes: DFR + IFR systems",
        "Base R stats integration",
        "Summary"
      ],
      "created": "2026-06-19 12:00:29",
      "modified": "2026-06-19 12:00:29",
      "commits": 1
    }
  ],
  "_score": 3.5440680443502757,
  "_indexed": true,
  "_nocasepkg": "kofn",
  "_universes": [
    "cran",
    "queelius"
  ],
  "_binaries": [
    {
      "r": "4.7.0",
      "os": "linux",
      "version": "0.4.0",
      "date": "2026-06-19T16:46:17.000Z",
      "distro": "noble",
      "commit": "74039558aa6fb5ceb59730184f6183d822c78f25",
      "fileid": "0cbfcb21fe6d9607b458ca0fffd94fe886f49bc684c08344a0758061d570f200",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/cran/actions/runs/27837770872"
    },
    {
      "r": "4.6.0",
      "os": "linux",
      "version": "0.4.0",
      "date": "2026-06-19T16:46:16.000Z",
      "distro": "noble",
      "commit": "74039558aa6fb5ceb59730184f6183d822c78f25",
      "fileid": "16754e1e8c7628f68d33c95ac71c7f313443c13f7dc7110d3ddde36a641a89ba",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/cran/actions/runs/27837770872"
    },
    {
      "r": "4.6.0",
      "os": "wasm",
      "version": "0.4.0",
      "date": "2026-06-19T16:46:14.000Z",
      "commit": "74039558aa6fb5ceb59730184f6183d822c78f25",
      "fileid": "2754acdfe810fec2ffdf35343a7afcc80117bdb8ba6bdd72a34f7450f96a522a",
      "status": "success",
      "buildurl": "https://github.com/r-universe/cran/actions/runs/27837770872"
    }
  ]
}