class_docstr: Inductive conformal regressor.
  
  Parameters
  ----------
  nc_function : BaseScorer
      Nonconformity scorer object used to calculate nonconformity of
      calibration examples and test patterns. Should implement ``fit(x, y)``,
      ``calc_nc(x, y)`` and ``predict(x, nc_scores, significance)``.
  
  Attributes
  ----------
  cal_x : numpy array of shape [n_cal_examples, n_features]
      Inputs of calibration set.
  
  cal_y : numpy array of shape [n_cal_examples]
      Outputs of calibration set.
  
  nc_function : BaseScorer
      Nonconformity scorer object used to calculate nonconformity scores.
  
  See also
  --------
  IcpClassifier
  
  References
  ----------
  .. [1] Papadopoulos, H., Proedrou, K., Vovk, V., & Gammerman, A. (2002).
      Inductive confidence machines for regression. In Machine Learning: ECML
      2002 (pp. 345-356). Springer Berlin Heidelberg.
  
  .. [2] Papadopoulos, H., & Haralambous, H. (2011). Reliable prediction
      intervals with regression neural networks. Neural Networks, 24(8),
      842-851.
class_docstr_tok: ["Inductive","conformal","regressor",".","Parameters","--","--","--","--","--","nc_function",":","BaseScorer","Nonconformity","scorer","object","used","to","calculate","nonconformity","of","calibration","examples","and","test","patterns",".","Should","implement","``","fit","(","x",",","y",")","``",",","``","calc_nc","(","x",",","y",")","``","and","``","predict","(","x",",","nc_scores",",","significance",")","``",".","Attributes","--","--","--","--","--","cal_x",":","numpy","array","of","shape","[","n_cal_examples",",","n_features","]","Inputs","of","calibration","set",".","cal_y",":","numpy","array","of","shape","[","n_cal_examples","]","Outputs","of","calibration","set",".","nc_function",":","BaseScorer","Nonconformity","scorer","object","used","to","calculate","nonconformity","scores",".","See","also","--","--","--","--","IcpClassifier","References","--","--","--","--","--","..","[","1","]","Papadopoulos",",","H.",",","Proedrou",",","K.",",","Vovk",",","V.",",","&","Gammerman",",","A",".","(","2002",")",".","Inductive","confidence","machines","for","regression",".","In","Machine","Learning",":","ECML","2002","(","pp",".","345-356",")",".","Springer","Berlin","Heidelberg",".","..","[","2","]","Papadopoulos",",","H.",",","&","Haralambous",",","H.","(","2011",")",".","Reliable","prediction","intervals","with","regression","neural","networks",".","Neural","Networks",",","24","(","8",")",",","842-851","."]
code: def __init__(
      self,
      nc_function: FunctionType,
      condition: bool = None,
      cal_size: int = None,
  ) -> None:
      super(IcpRegressor, self).__init__(
          nc_function, condition, cal_size
      )
  
imports: from collections import defaultdict
  from functools import partial
  from typing import Optional, Union
  import numpy
  from sklearn.base import BaseEstimator
  from lightwood.analysis.nc.base import RegressorMixin, ClassifierMixin, TSMixin
  from types import FunctionType
label_desc: Use image node_id 1 to create a new IcpRegressor object from inherited base classes: BaseIcp, RegressorMixin with example: obj = IcpRegressor(nc_function, condition, cal_size)