{"categories":[{"label":"Mathematics","url":"https://skillfed.io/packages/category/scientific-engineering-mathematics/3"}],"enrichment":{"capability":"Fits piecewise linear regression models to data with one or more breakpoints, estimating segment gradients and breakpoint positions with confidence intervals.","skillfed_tags":["regression-analysis","statistical-modeling","breakpoint-detection"],"use_cases":["Detect and quantify shifts in trend in time-series data, such as changes in growth rate before and after a policy intervention.","Identify optimal threshold points in dose-response or dose-effect studies where biological or physical response changes slope.","Analyze piecewise relationships in economic or environmental data where structural breaks occur at known or unknown transition points.","Compare competing segmented models using BIC to select the number of breakpoints that best explains the data.","Extract confidence intervals around estimated breakpoint positions for hypothesis testing or uncertainty quantification."],"what_it_does":"Piecewise-regression implements Muggeo's iterative algorithm to fit piecewise linear models\u2014straight lines with one or more breakpoints where the slope changes. You provide x and y data plus either initial breakpoint guesses or a desired number of breakpoints, and the package estimates the segment gradients, breakpoint positions, and confidence intervals for all parameters. It includes a Davies test to assess whether breakpoints exist statistically.\n\nThe package uses bootstrap restarting to escape local optima and improve the chance of finding a global solution, though convergence is not guaranteed. It also offers a ModelSelection tool based on Bayesian Information Criterion (BIC) to compare models with different numbers of breakpoints. Results can be extracted as structured data or plotted with matplotlib for visualization of the fit, breakpoints, and confidence bands.","worth_installing":"Yes, if you need to fit piecewise linear models with statistical inference. The package is well-maintained enough (last commit mid-2024), has no known vulnerabilities, and low install friction. Dormant status is not a blocker for a stable, narrowly-scoped tool. Install with caution if you require active development or frequent updates; for one-off analysis or established workflows, it is reliable."},"id":"piecewise-regression","links":{"html":"https://skillfed.io/packages/piecewise-regression","md":"https://skillfed.io/packages/piecewise-regression.md","pypi":"https://pypi.org/project/piecewise-regression/"},"maintenance":{"status":"dormant"},"meta":{"latest_release":"2023-12-18","license_spdx":null,"license_treatment":"permissive","name":"piecewise-regression","python_support":"unspecified","summary":"piecewise (segmented) regression in python"},"popularity":{"monthly_downloads":133799,"position":11495,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"1.5.0"}
