scikit-learn compatible quantile forests.
Project description
quantile-forest
quantile-forest offers a Python implementation of quantile regression forests compatible with scikit-learn.
Quantile regression forests (QRF) are a non-parametric, tree-based ensemble method for estimating conditional quantiles, with application to high-dimensional data and uncertainty estimation [1]. The estimators in this package are performant, Cython-optimized QRF implementations that extend the forest estimators available in scikit-learn to estimate conditional quantiles. The estimators can estimate arbitrary quantiles at prediction time without retraining and provide methods for out-of-bag estimation, calculating quantile ranks, and computing proximity counts. They are compatible with and can serve as drop-in replacements for the scikit-learn variants.
Example of fitted model predictions and prediction intervals on California housing data (code)
Quick Start
Install quantile-forest from PyPI using pip
:
pip install quantile-forest
Usage
from quantile_forest import RandomForestQuantileRegressor
from sklearn import datasets
X, y = datasets.fetch_california_housing(return_X_y=True)
qrf = RandomForestQuantileRegressor()
qrf.fit(X, y)
y_pred = qrf.predict(X, quantiles=[0.025, 0.5, 0.975])
Documentation
An installation guide, API documentation, and examples can be found in the documentation.
References
[1] N. Meinshausen, "Quantile Regression Forests", Journal of Machine Learning Research, 7(Jun), 983-999, 2006. http://www.jmlr.org/papers/volume7/meinshausen06a/meinshausen06a.pdf
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for quantile_forest-1.2.4-cp312-cp312-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1cc1768dac4a2c81e52bef5761296a5dd456a48824c78f2bc5f426954aeaab6f |
|
MD5 | 995247ce0735a50652224381519b35cf |
|
BLAKE2b-256 | d15dbbc49a835320cf1a4baa347092bff53f6c1213ac3da8f584e9b642b5ad4f |
Hashes for quantile_forest-1.2.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 061395986da6b5b74038458cbe413beb560d8ec953d04b0bc6b8c3ccf64636df |
|
MD5 | 63a835f2239503d168581335e9fbf509 |
|
BLAKE2b-256 | 2f3834b6f75858bb27e05ed9e0171b8b0565407812fa6e79d90e8bf5d43f83a4 |
Hashes for quantile_forest-1.2.4-cp312-cp312-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9d24a4761256d2b7fc6cc7e9340be8fce3d1f1025093c62b4d6fbb44121ff9a4 |
|
MD5 | 8cc93e5b8c6d95eea4f8f48ee4dfda16 |
|
BLAKE2b-256 | d6b2467675056f457eb9ce0d83588bff450ba2c0590ba53ab4914d873a8714ea |
Hashes for quantile_forest-1.2.4-cp312-cp312-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9433af671e46426c00f1db6a20f3cac91449622728eaeb3cad2e683108fa56cd |
|
MD5 | 187d8114140622b80eae2442c1e823f9 |
|
BLAKE2b-256 | 3df9ec81e56dffef800afef64c7b33c08f05e3f6cad7aae436228db783fa3be4 |
Hashes for quantile_forest-1.2.4-cp312-cp312-macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f72a94ee62a85804f7a4253fda86804a31bbb18d2242f0f30a50d294dbe32db0 |
|
MD5 | 144f5dc524ed3df730d7ef1a6187a960 |
|
BLAKE2b-256 | 7c7892dd8131781e24231da9c89e36283d24172f7e7fbafae0e5ab4e86f84178 |
Hashes for quantile_forest-1.2.4-cp311-cp311-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 039596b6b156bed83826c19cd4a036eb79c7a30a0414fabdd10bfab2ed9773ed |
|
MD5 | 2d928bdc4d5447b97337965a73ba7bdc |
|
BLAKE2b-256 | d31528bfdd6408e51a519075364eaf09b03d2d2f05f696e80bddba9a74b806d5 |
Hashes for quantile_forest-1.2.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b28da0cbe628cd936845e1f5dabe716ade8759aa787f4c0b3a45da200560208e |
|
MD5 | 5f116e43da0ab06e8a8ba125924d5e99 |
|
BLAKE2b-256 | 40f1b3204555f4de9df0fab4f5b34240a0aceffdd7952e3d65b1babc6c45c9fb |
Hashes for quantile_forest-1.2.4-cp311-cp311-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ab1275959fc31210a3a60ef678312637fdb4da2e8645fba0aa1671bf30ad3166 |
|
MD5 | 782ec4e9188b4fde03a97f63d2f04ac2 |
|
BLAKE2b-256 | 1e0a020cbcba6fdfa3d3278aaae4f78e67605e27543068864e1167fed97c1a4f |
Hashes for quantile_forest-1.2.4-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b863ef4c0cd11d9b3a9ad5d18bc1c5f2eae5fbc1ec4eccfbd00ac672ff6a2122 |
|
MD5 | 5fecf8a918dd4241ba896d9574e4cd8f |
|
BLAKE2b-256 | 0ad4c5125d775ec5dcccc948dca2b7d0c7b12173bab349aaeec046a36a54cc85 |
Hashes for quantile_forest-1.2.4-cp311-cp311-macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3d928fade1309b057e5fc398d3fc0330d7621ea59a1a13d9820f69c58e4eba34 |
|
MD5 | 87112be98684fef8a6974afbb317dff1 |
|
BLAKE2b-256 | 6f9d9a5269b64e5c0af2ddaed31a85f359b3f9a565c610a5415cefc998239757 |
Hashes for quantile_forest-1.2.4-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3acc7f9164c3949f351c9beecf7bdb1da108f591a10008811cb14532f8d361b6 |
|
MD5 | 56a740494844bde78831402d9ee84032 |
|
BLAKE2b-256 | 303a5f7edfa9470e39f8db398ebc75a5ea8501ca8c7cdf98e73abef1395fc076 |
Hashes for quantile_forest-1.2.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 32ff4271bc3234f4f00559b3c78a748bbb159ede19fad39a058f3ea92d48d2f7 |
|
MD5 | fa6e7bf22e4646156bd523d83db0c32d |
|
BLAKE2b-256 | 07804da9520f966d9ca8c0991b96e1307493b62d0ddaf4cb28321a5d0766d858 |
Hashes for quantile_forest-1.2.4-cp310-cp310-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 135070e567def9bbe186d8528cf0b6e091cb055158cb655f0c69ff1c3b63d1c0 |
|
MD5 | 06df9767fb4555dac7d1e42e830240bc |
|
BLAKE2b-256 | 7636377d7879120a5f44f1a8252170d5f7c5cd66de5e1b6ee82709991c14b4a5 |
Hashes for quantile_forest-1.2.4-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 735a19334c41e71ce21ce193ed7bff33bc6d0cec8184a85fc34a4b3c3a9e1f48 |
|
MD5 | 8232665e1b092826307e68a871c50a72 |
|
BLAKE2b-256 | 1d9ee18fa844353302cd3b6f43416bbcdea511620953e071cdbcdff29da77919 |
Hashes for quantile_forest-1.2.4-cp310-cp310-macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4b2776a44f5ad20c46d9f101bd99ed52c4ea910448d7e81a57bd3d3817cf2308 |
|
MD5 | 890f937ba4de67ce75b93372a7d4228e |
|
BLAKE2b-256 | ce91692ff368689241a360aa27315ac0bb0ab28b927b34ffee6308721c0e783f |
Hashes for quantile_forest-1.2.4-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2f503cca44731fd7e3afb1795d114579940efb86cc656427c80060eb3f7f6f5a |
|
MD5 | fb7abb81efba4123c73efaf67a123d3d |
|
BLAKE2b-256 | 393fb163ccd5cc75919d931a508145b98b827868eceae22a37d464ba5e0f3a48 |
Hashes for quantile_forest-1.2.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 31c5396895afc79ccdf6d4203c0d2f30333aede453ddd1f3e601e052783d85ed |
|
MD5 | c9cf66bc8a0f383451a5d228ca73fab5 |
|
BLAKE2b-256 | f257becbcb3315ea24a737f0badca9ca9161d8aa4fdadcf5263b6a23d0282e1e |
Hashes for quantile_forest-1.2.4-cp39-cp39-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8c100754e2a7e41fa8d28e58d56b39135b0062202579a866b72a5688d8b8de6a |
|
MD5 | 747b2fcac05eed70d3cf922b7a7bd4e2 |
|
BLAKE2b-256 | ef4878e87151a17f442552166ac269d7c4419c808d61ea10a81b010183ce172f |
Hashes for quantile_forest-1.2.4-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | abd87d5b1f234b9ccf4c10700c043a20ee786d26ac393ffa9163b4649784d9d6 |
|
MD5 | 68f300fc392c09b12df46bfcc3396e5a |
|
BLAKE2b-256 | 8e4d430ec33fe0ea18d780b6e3dd758927407fca3174ede0763e813e6534d389 |
Hashes for quantile_forest-1.2.4-cp39-cp39-macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 92dcbaa652b8f2dbe39cb0b68dc38d6ec2b63ec18a76a6a14b4903e3dfdb8fc7 |
|
MD5 | 444f399309f99bc616d5c45422c07c9d |
|
BLAKE2b-256 | 0b1a63a24ad597b198850ea9ef2ba552bc7255cd7b470b6d265420f4f08bad26 |
Hashes for quantile_forest-1.2.4-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 531b06040a57d992783da7c605e40211415009cc0a18b1ac78a4e84fc0fb1d89 |
|
MD5 | 237515f970f5b20ab0e3cfd4845b3e1f |
|
BLAKE2b-256 | dd2e8de0b2dbfd08e63ad3d30cc3efe1f06b7e6b3745e9dd5dc4b7d036cbad3c |
Hashes for quantile_forest-1.2.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 176d3f11edea0e484c43ee10ca8730c7f16e08cb21a1344581218ffd3a2a8521 |
|
MD5 | be00e01be613300835725f61e1c05aed |
|
BLAKE2b-256 | e8515f5d9285ab107adfaae1c4a88ea7b68557ee30b104b2073a34f434bedc9b |
Hashes for quantile_forest-1.2.4-cp38-cp38-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fbc6350b480006a1af75bca7eac7ad31942265c35a0a260b72a0864adcc432ca |
|
MD5 | a1591db8756e16cefee6ea52b13c0759 |
|
BLAKE2b-256 | 5b65411d0b72286d06e4b8654c9a432fcad73225b48341ff87f2691480647b3d |
Hashes for quantile_forest-1.2.4-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ce5962e1802877440779ab09653a6777d8302476eef59ac79603f03d55247e72 |
|
MD5 | dde509666581409268b59b1214db4bb9 |
|
BLAKE2b-256 | a8dbaac45310a72ed4f1f053173226f9bd16ea6a72e69ba1603cd5ab3b6b15fa |
Hashes for quantile_forest-1.2.4-cp38-cp38-macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7946d2e363aa47eff5c775e0c745e918914bd7e921fbcff3e1a97918898335c9 |
|
MD5 | 129d6ab5b628e43741bdbb48c3d36951 |
|
BLAKE2b-256 | 8adc7fff91f75c26a221aa53950346ee51ae03158d272dc7a97394d3b48afd3f |