Skip to main content

Prediction intervals for trees using conformal intervals - pitci

Project description

Prediction Intervals for Trees using Conformal Intervals

PyPI Codacy branch coverage Read the Docs GitHub GitHub last commit GitHub issues Build

Introduction

The basic idea of inductive conformal intervals is to use a calibration set to learn a given quantile of the error distribution on that set. This quantile is used as the basis for prediction intervals on new data.

However this is often not especially useful in practice as every new prediction will recieve the same interval. Instead we want to scale this interval according to the input data. Intuitively we want to increase the interval where we have less confidence about the data and associated prediction and decrease it where we have more confidence.

In order to produce a scaling factor value captures the confidence or familiarity we have with some data compared to our calibration set, pitci uses the number of training data rows that fell into the specific leaf nodes that were visited in making the prediction, summed across all trees.

For a full list of the supported libraries and more detail on the methods implmeneted, see the docs.

Install

The easiest way to get pitci is directly from PyPI using;

pip install pitci

Documentation

The documentation for pitci can be found here.

For information on how to build the documentation locally see the docs README.

Examples

There are various example notebooks demonstrating how to use the package in the examples folder in the repo.

Build

pitci uses flit as the package build tool.

To install pitci for development, use the following commands from the root directory;

pip install "flit>=2,<4"
flit install

The default deps flag for flit is all so this will install all of the libraries required for testing and creating the docs.

To install pitci in editable mode (i.e. the equivalent of pip install . -e) use the symlink flag;

flit install --symlink

See the flit docs for all the command line options for flit.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pitci-0.3.1.tar.gz (73.2 kB view details)

Uploaded Source

Built Distribution

pitci-0.3.1-py3-none-any.whl (23.5 kB view details)

Uploaded Python 3

File details

Details for the file pitci-0.3.1.tar.gz.

File metadata

  • Download URL: pitci-0.3.1.tar.gz
  • Upload date:
  • Size: 73.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.25.1

File hashes

Hashes for pitci-0.3.1.tar.gz
Algorithm Hash digest
SHA256 c6485a1f93cfcd238efa923d66b63c2371ba6d8c4745888d4dd0ca910672e766
MD5 d4d6953d89322f6211127357a818865a
BLAKE2b-256 6e69fe7e3c0abaf8c55c1e8048946a4263f322c529d545d3b185586ebe33b935

See more details on using hashes here.

File details

Details for the file pitci-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: pitci-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 23.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.25.1

File hashes

Hashes for pitci-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 830d9678569c0adb34ec295bac01eb57ba50f1bb20500e22e3586959df32c0fe
MD5 0da3b66cc1ce8b1a88a16738f54db68f
BLAKE2b-256 bf005b69ab46477f01b2a0f221077f6d6b02a6f8da1a35982d24488fa6b032aa

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page