changepoint
A toolkit for Bayesian change point detection
Science Score: 23.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
○DOI references
-
✓Academic publication links
Links to: arxiv.org -
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (9.1%) to scientific vocabulary
Keywords
Repository
A toolkit for Bayesian change point detection
Basic Info
Statistics
- Stars: 31
- Watchers: 6
- Forks: 2
- Open Issues: 2
- Releases: 6
Topics
Metadata Files
README.md
changepoint - Change point detection for Rust
Changepoint is a library for doing change point detection for streams of data.
See this for more info on the Python bindings.
Algorithms
Includes the following change point detection algorithms:
* Bocpd -- Online Bayesian Change Point Detection Reference.
* BocpdTruncated -- Same as Bocpd but truncated the run-length distribution when those lengths are unlikely.
* Argpcp -- Gaussian Process Change Point detector Reference
Example
``rust
//! A demo of the online Bayesian change point detection on
//! the 3-month Treasury Bill Secondary Market Rate from
//!
//! After this example is run, the filetrasury_bill.ipynb` can be run to generate
//! plots for this dataset.
//!
//! > Board of Governors of the Federal Reserve System (US), 3-Month Treasury Bill: Secondary
//! > Market Rate [TB3MS], retrieved from FRED, Federal Reserve Bank of St. Louis;
//! > https://fred.stlouisfed.org/series/TB3MS, August 5, 2019.
use changepoint::{utils::, BocpdTruncated, BocpdLike}; use rv::prelude::; use std::io; use std::path::PathBuf; use std::fs::readtostring;
fn main() -> io::Result<()> {
// Parse the data from the TB3MS dataset
let mut csvpath = PathBuf::from(env!("CARGOMANIFESTDIR"));
csvpath.push("resources/TB3MS.csv");
let data: String = readtostring(&csvpath)?;
let (dates, pctchange): (Vec<&str>, Vec
// Create the Bocpd processor
let mut cpd = BocpdTruncated::new(
250.0,
NormalGamma::new_unchecked(0.0, 1.0, 1.0, 1.0),
);
// Feed data into change point detector and generate a sequence of run-length distributions
let rs: Vec<Vec<f64>> = pct_change
.iter()
.map(|d| cpd.step(d).into())
.collect();
// Determine most likely change points
let change_points: Vec<usize> = map_changepoints(&rs);
let change_dates: Vec<&str> =
change_points.iter().map(|&i| dates[i]).collect();
// Write output for processing my `trasury_bill.ipynb`.
write_data_and_r(
"treasury_bill_output",
&pct_change,
&rs,
&change_points,
)?;
println!("Most likely dates of changes = {:#?}", change_dates);
Ok(())
} ```
To run this example, from the source root, run cargo run --example treasury_bill.
The partner notebook can be used to generate the following plots:

Owner
- Name: promised-ai
- Login: promised-ai
- Kind: organization
- Repositories: 1
- Profile: https://github.com/promised-ai
GitHub Events
Total
- Watch event: 12
- Pull request review event: 1
- Pull request event: 2
- Fork event: 1
Last Year
- Watch event: 12
- Pull request review event: 1
- Pull request event: 2
- Fork event: 1
Committers
Last synced: over 1 year ago
Top Committers
| Name | Commits | |
|---|---|---|
| Mike Schmidt | s****t@g****m | 59 |
| Baxter Eaves | b****r@g****m | 11 |
| Baxter Eaves | b****x@r****i | 8 |
| Ben Sully | b****8@g****m | 1 |
| Jose Storopoli | t****i@g****m | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 6 months ago
All Time
- Total issues: 1
- Total pull requests: 11
- Average time to close issues: 15 days
- Average time to close pull requests: 12 days
- Total issue authors: 1
- Total pull request authors: 3
- Average comments per issue: 2.0
- Average comments per pull request: 0.45
- Merged pull requests: 9
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 0
- Pull requests: 3
- Average time to close issues: N/A
- Average time to close pull requests: 24 minutes
- Issue authors: 0
- Pull request authors: 2
- Average comments per issue: 0
- Average comments per pull request: 0.33
- Merged pull requests: 1
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- HilaManor (1)
Pull Request Authors
- schmidmt (9)
- ebw44 (4)
- sd2k (2)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 2
-
Total downloads:
- cargo 53,864 total
- pypi 1,603 last-month
-
Total dependent packages: 0
(may contain duplicates) -
Total dependent repositories: 4
(may contain duplicates) - Total versions: 30
- Total maintainers: 5
pypi.org: changepoint
A Bayesian change point library
- Documentation: https://changepoint.readthedocs.io/
- License: MIT
-
Latest release: 0.3.2
published over 1 year ago
Rankings
Maintainers (3)
crates.io: changepoint
Change Point Detection in Rust
- Documentation: https://docs.rs/changepoint/
- License: MIT
-
Latest release: 0.14.2
published over 1 year ago
Rankings
Maintainers (2)
Dependencies
- PyO3/maturin-action v1 composite
- Swatinem/rust-cache v2 composite
- actions/checkout v3 composite
- actions/download-artifact v3 composite
- actions/setup-python v4 composite
- actions/upload-artifact v3 composite
- dtolnay/rust-toolchain stable composite
- Swatinem/rust-cache v2 composite
- actions/checkout v3 composite
- dtolnay/rust-toolchain stable composite
- assert 0.7 development
- criterion 0.5 development
- serde_json 1 development
- approx 0.5
- derive_more 0.99
- nalgebra 0.32
- ndarray 0.15
- num-traits 0.2
- rand 0.8
- rayon 1.4
- rv 0.16
- serde 1
- serde_derive 1
- special 0.10
- hypothesis ==6.65.2 development
- maturin ==0.14.10 development
- pytest ==7.2.0 development
- pytest-cov ==4.0.0 development
- pytest-xdist ==3.1.0 development
- autodocsumm ==0.2.10
- commonmark ==0.9.1
- hypothesis ==6.75.1
- livereload ==2.6.3
- numpy *
- numpydoc ==1.5.0
- pandas *
- pyarrow *
- pydata-sphinx-theme ==0.13.3
- sphinx ==6.2.1
- sphinx-autosummary-accessors ==2023.4.0
- sphinx-copybutton ==0.5.1
- sphinx-design ==0.4.1
- sphinx-favicon ==1.0.1
- sphinx-rtd-theme ==1.2.2
- sphinxcontrib-applehelp ==1.0.4
- sphinxcontrib-devhelp ==1.0.2
- sphinxcontrib-htmlhelp ==2.0.1
- sphinxcontrib-jsmath ==1.0.1
- sphinxcontrib-napoleon ==0.7
- sphinxcontrib-qthelp ==1.0.3
- sphinxcontrib-serializinghtml ==1.1.5
- black ==23.1.0
- blackdoc ==0.3.7
- mypy ==1.0.0
- ruff ==0.0.247