Skip to content

flashlight

1.0.0Package record

Shed Light on Black Box Machine Learning Models

2packages depend
6.4Kdownloads / year
83.9%test coverage
13/13flavors OK

Overview

About

Shed light on black box machine learning models by the help of model performance, variable importance, global surrogate models, ICE profiles, partial dependence (Friedman J. H. (2001) doi:10.1214/aos/1013203451), accumulated local effects (Apley D. W. (2016) doi:10.48550/arXiv.1612.08468), further effects plots, interaction strength, and variable contribution breakdown (Gosiewska and Biecek (2019) doi:10.48550/arXiv.1903.11420). All tools are implemented to work with case weights and allow for stratified analysis. Furthermore, multiple flashlights can be combined and analyzed together.

Changes in 1.0.0

New functionality

  • plot.light_effects() has gained an argument recode_labels to modify the curve labels.

Bug fixes

  • More than one "by" variable would raise an error when creating the "flashlight" object, see #62.
  • Fix compatibility issue with ggplot v 4.0.

Deprecated functionality

  • add_shap(): Deprecated in favor of {kernelshap} or {fastshap}.
  • Consequently, type = "shap" in light_profile(), light_importance(), light_scatter(), and light_profile2d() is deprecated as well.
  • plot_counts() is deprecated.
  • light_recode() is deprecated.
  • The option stats = "quartile"of light_effects() and light_profile() is deprecated.
  • Column names of resulting data objects cannot be set via options() anymore.
Show all changes in 1.0.0Hide the rest of the changes in 1.0.0

Exported -> internal

The following functions are now internal:

  • grouped_center()
  • grouped_counts()
  • grouped_stats()
  • grouped_weighted_mean()
  • all_identical()
  • auto_cut()
  • common_breaks()
  • cut3()

Minor changes

  • most_important() is not S3 anymore.
  • plot.light_breakdown() and plot.light_importance() do not use flipped coordinates anymore.

Less dependencies

  • {cowplot} and {withr} packages have been removed from "imports".

Announcements for upcoming version 1.1.0

  • The argument "stats" in light_effects() and light_profile() will be removed. It has no effect anymore.

Maintenance

  • Update code coverage version.
  • Fix NOTES on CRAN results page.

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 3.0 min · r-release-macos-x86_64
Status changes
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 1.0.0
READMEYes · 215 wordsVignettesYes · 1 · dynamicNEWSYes · 67% structured · mentions 1.0.0Citation fileNo
Help pages
36
Examples that run
100%24 run in a plain check
Exported functions with examples
85%
Documented parameters
96%
Return-value docs
100%
Help pages citing references
19%

Downloads

6.4K
CRAN downloads in the past year
Rank #5,116 · ~18/day · ~537/mo
Daily download trend is not available in this view yet.
75330 days
1.6K90 days
6.4K1 year
Compare downloads with other packages →
Also on139 r2u3 autocran

Repository

25Stars
4Forks
3Open issues
0Open PRs
5Releases
290Commits
2Commit identities
interpretabilityinterpretable-machine-learningmachine-learningrr-packagexai
License file reads as GPL-2.0 · 290 commits · Last activity 2025-10-13 · 0% stars, 30d
Responsiveness
How these are sampled
PRs merged (all time)
95%
Median days to close, 50 most recently updated closed issues
5
Median days to close, 50 most recently updated closed PRs
0

Stars over time

2025-05-16 · 232026-07-07 · 25
PracticesBeta

9 development-tooling and community-health practices detected across 5 families in the upstream repository

Checks run against github.com/mayer79/flashlight on 2026-10-21.

Continuous integration (2)
GitHub ActionsR CMD check workflow

The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel

Docs source (2)

GitHub Pages site last deployed 2025-10-13 · The repository has a site deploy workflow

Coverage (1)
Coverage reporting
CRAN release process (3)
cran-comments.mdrevdep/CRAN-SUBMISSION
Show all practicesHide 1 practice
Lint, format, editor (1)
RStudio project
How this is detected·Detection ruleset v4 (2026-10-20)

Dependencies

Declared dependencies
11 external dependencies (excludes base and recommended)

Installing flashlight adds 31 packages (15 with compiled code, 29 MB of source tarballs). Heaviest: stringi 11 MB, ggplot2 6.0 MB, isoband 1.5 MB.

Depends (1)
R >= 3.2.0
LinkingTo (0)
none
Enhances (0)
none
Reverse dependencies
2direct
0indirect
Imports 2
Depends, Imports or LinkingTo, most downloaded first

People & History

People (1)
Author, Maintainer since 0.1.0 (2019), Copyright holder
Releases (15)

Pick two releases to compare their code metrics.

  • R
    R 4.6.0 released · 2026-04-24
  • 1.0.0Latest
    record
    2025-10-13 · current release · diff ↗ ·
    removed 7 exports
    all_identical, auto_cut, cut3, grouped_center, grouped_counts, grouped_stats, grouped_weighted_mean
  • R
    R 4.5.0 released · 2025-04-11
  • R
    R 4.4.0 released · 2024-04-24
  • 0.9.0
    record
    2023-05-10 · diff ↗
  • R
    R 4.3.0 released · 2023-04-21
  • R
    R 4.2.0 released · 2022-04-22
  • R
    R 4.1.0 released · 2021-05-18
  • 0.8.0
    record
    2021-04-21 · diff ↗ ·
    added 3 exports
    is.light_profile2d, is.light_profile2d_multi, light_profile2d
  • 0.7.5
    record
    2021-02-13 · diff ↗
  • 0.7.4
    record
    2021-01-10 · diff ↗
  • 0.7.3
    record
    2020-06-20 · diff ↗ ·
    removed 1 export
    midpoints
  • R
    R 4.0.0 released · 2020-04-24
  • 0.7.2
    record
    2020-04-14 · diff ↗
  • 0.7.1
    record
    2020-03-20 · diff ↗
  • 0.7.0
    record
    2020-03-12 · diff ↗ ·
    added 3 exports
    is.light_global_surrogate, is.light_global_surrogate_multi, light_global_surrogate
Show 7 earlier eventsHide 7 earlier events
  • 0.6.0
    record
    2020-01-19 · diff ↗ ·
    added 5 exports
    add_shap, is.light_scatter, is.light_scatter_multi, is.shap, light_scatter
  • 0.5.0
    record
    2019-12-05 · diff ↗ ·
    added 3 exports
    grouped_center, grouped_counts, grouped_weighted_mean
  • 0.4.0
    record
    2019-11-10 · diff ↗ ·
    added 1 export
    light_interaction
  • 0.3.0
    record
    2019-10-13 · diff ↗
  • 0.2.0
    record
    2019-09-18 · diff ↗ ·
    added 3 exports
    is.light_breakdown, is.light_breakdown_multi, light_breakdown
  • 0.1.0
    record
    2019-08-25
  • R
    R 3.6.0 released · 2019-04-26

Package metadata

First published
2019-08-25
Total releases
15 / 7 yrs
License
GPL (>= 2) OSI
Minimum R
≥ 3.2.0
Download size
436 KB

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("flashlight")
Mayer, M. (2025). flashlight: Shed Light on Black Box Machine Learning Models (Version 1.0.0) [Computer software]. https://doi.org/10.32614/CRAN.package.flashlight

This package has no citation file, so citation() returns this entry built from DESCRIPTION.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for flashlight version 1.0.0 [Data set]. HJJB, LLC. Data release v2026-10-23. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-23, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy