# Changes in [10393:4dbd54af3ac8:10400:aec1e14d2267] in orange

Ignore:
Files:
1 deleted
8 edited

Unmodified
Added
Removed
• ## Orange/OrangeWidgets/Unsupervised/OWDistanceFile.py

 r9671 import OWGUI import orange import orngMisc import exceptions import os.path
• ## Orange/regression/base.py

 r10238 """\ ==================================== Basic regression learner (``basic``) ==================================== ======================= Base regression learner ======================= .. index:: regression class BaseRegressionLearner(Orange.core.Learner): """ Base Regression Learner "learns" how to treat the discrete variables and missing data. """Fitting regressors typically requires data that has only continuous-valued features and no missing values. This class provides methods for appropriate transformation of the data and serves as a base class for most regressor classes. """ def set_imputer(self, imputer=None): """ Sets the imputer for missing values. """ Set the imputer for missing data. :param imputer: function which imputes the missing values, if None, the default imputer: mean for the continuous variables and most frequent value (majority) for discrete variables :param imputer: function which constructs the imputer for the missing values, if ``None``, the default imputer replaces missing continuous data with the average of the corresponding variable and missing discrete data with the most frequent value. :type imputer: None or Orange.feature.imputation.ModelConstructor """ def set_continuizer(self, continuizer=None): """ Sets the continuizer of the discrete variables """Set the continuizer of the discrete variables :param continuizer: function which replaces the categorical (dicrete) variables with numerical variables. If None, the default continuizer is used :param continuizer: function which replaces the categorical (dicrete) variables with numerical variables. If ``None``, the default continuizer is used :type continuizer: None or Orange.data.continuization.DomainContinuizer """ def impute_table(self, table): """ Imputes missing values. Returns a new :class:`Orange.data.Table` object """Impute missing values and return a new :class:`Orange.data.Table` object :param table: data instances. def continuize_table(self, table): """ Continuizes the discrete variables. Returns a new :class:`Orange.data.Table` object """Replace discrete variables with continuous and return a new instance of :class:`Orange.data.Table`. :param table: data instances.
• ## Orange/regression/tree.py

 r10294 *************************** Regression tree shares its implementation with Orange.classification.tree.TreeLearner, but uses a different set of functions to evaluate node splitting and stop criteria. Usage of regression trees is straightforward as demonstrated on the following example (:download:`regression-tree-run.py `): Regression tree shares its implementation with :obj:`Orange.classification.tree.TreeLearner`, but uses a different set of functions to evaluate node splitting and stop criteria. Usage of regression trees is straightforward as demonstrated on the following example (:download:`regression-tree-run.py `): .. literalinclude:: code/regression-tree-run.py
• ## Orange/statistics/basic.py

 r9994 """ .. index:: Basic Statistics for Continuous Features ======================================== Basic Statistics for Continuous Features ======================================== The are two simple classes for computing basic statistics for continuous features, such as their minimal and maximal value or average: :class:`Orange.statistics.basic.Variable` holds the statistics for a single variable and :class:`Orange.statistics.basic.Domain` behaves like a list of instances of the above class for all variables in the domain. .. class:: Variable Computes and stores minimal, maximal, average and standard deviation of a variable. It does not include the median or any other statistics that can be computed on the fly, without remembering the data; such statistics can be obtained classes from module :obj:`Orange.statistics.distribution`. Instances of this class are seldom constructed manually; they are more often returned by :obj:`Domain` described below. .. attribute:: variable The variable to which the data applies. .. attribute:: min Minimal value encountered .. attribute:: max Maximal value encountered .. attribute:: avg Average value .. attribute:: dev Standard deviation .. attribute:: n Number of instances for which the value was defined. If instances were weighted, :obj:`n` holds the sum of weights .. attribute:: sum Weighted sum of values .. attribute:: sum2 Weighted sum of squared values .. .. attribute:: holdRecomputation Holds recomputation of the average and standard deviation. .. method:: add(value[, weight=1]) Add a value to the statistics: adjust :obj:`min` and :obj:`max` if necessary, increase :obj:`n` and recompute :obj:`sum`, :obj:`sum2`, :obj:`avg` and :obj:`dev`. :param value: Value to be added to the statistics :type value: float :param weight: Weight assigned to the value :type weight: float .. .. method:: recompute() Recompute the average and deviation. .. class:: Domain ``statistics.basic.Domain`` behaves like an ordinary list, except that its elements can also be indexed by variable names or descriptors. .. method:: __init__(data[, weight=None]) Compute the statistics for all continuous variables in the data, and put :obj:`None` to the places corresponding to variables of other types. :param data: A table of instances :type data: Orange.data.Table :param weight: The id of the meta-attribute with weights :type weight: `int` or none .. method:: purge() Remove the :obj:`None`'s corresponding to non-continuous features; this truncates the list, so the indices do not respond to indices of variables in the domain. part of :download:`distributions-basic-stat.py ` .. literalinclude:: code/distributions-basic-stat.py :lines: 1-10 Output:: feature   min   max   avg sepal length 4.300 7.900 5.843 sepal width 2.000 4.400 3.054 petal length 1.000 6.900 3.759 petal width 0.100 2.500 1.199 part of :download:`distributions-basic-stat.py ` .. literalinclude:: code/distributions-basic-stat.py :lines: 11- Output:: 5.84333467484 """ from Orange.core import BasicAttrStat as Variable from Orange.core import DomainBasicAttrStat as Domain
• ## docs/reference/rst/Orange.regression.rst

 r9372 ########################### Orange uses the term `classification` to also denote the regression. For instance, the dependent variable is called a `class variable` even when it is continuous, and models are generally called classifiers. A part of the reason is that classification and regression rely on the same set of basic classes. Please see the documentation on :doc:`Orange.classification` for information on how to fit models in general. Orange contains a number of regression models which are listed below. .. toctree:: :maxdepth: 4 :maxdepth: 1 Orange.regression.mean Orange.regression.base Orange.regression.linear Orange.regression.lasso Orange.regression.tree .. automodule:: Orange.regression.base
• ## docs/reference/rst/Orange.statistics.basic.rst

 r9372 .. automodule:: Orange.statistics.basic .. py:currentmodule:: Orange.statistics.basic .. index:: Basic Statistics for Continuous Features ==================================================== Basic Statistics for Continuous Features (``basic``) ==================================================== The are two simple classes for computing basic statistics for continuous features, such as their minimal and maximal value or average: :class:`Orange.statistics.basic.Variable` holds the statistics for a single variable and :class:`Orange.statistics.basic.Domain` behaves like a list of instances of the above class for all variables in the domain. .. class:: Variable Computes and stores minimal, maximal, average and standard deviation of a variable. It does not include the median or any other statistics that can be computed on the fly, without remembering the data; such statistics can be obtained classes from module :obj:`Orange.statistics.distribution`. Instances of this class are seldom constructed manually; they are more often returned by :obj:`Domain` described below. .. attribute:: variable The variable to which the data applies. .. attribute:: min Minimal value encountered .. attribute:: max Maximal value encountered .. attribute:: avg Average value .. attribute:: dev Standard deviation .. attribute:: n Number of instances for which the value was defined. If instances were weighted, :obj:`n` holds the sum of weights .. attribute:: sum Weighted sum of values .. attribute:: sum2 Weighted sum of squared values .. .. attribute:: holdRecomputation Holds recomputation of the average and standard deviation. .. method:: add(value[, weight=1]) Add a value to the statistics: adjust :obj:`min` and :obj:`max` if necessary, increase :obj:`n` and recompute :obj:`sum`, :obj:`sum2`, :obj:`avg` and :obj:`dev`. :param value: Value to be added to the statistics :type value: float :param weight: Weight assigned to the value :type weight: float .. .. method:: recompute() Recompute the average and deviation. .. class:: Domain ``statistics.basic.Domain`` behaves like an ordinary list, except that its elements can also be indexed by variable names or descriptors. .. method:: __init__(data[, weight=None]) Compute the statistics for all continuous variables in the data, and put :obj:`None` to the places corresponding to variables of other types. :param data: A table of instances :type data: Orange.data.Table :param weight: The id of the meta-attribute with weights :type weight: `int` or none .. method:: purge() Remove the :obj:`None`'s corresponding to non-continuous features; this truncates the list, so the indices do not respond to indices of variables in the domain. part of :download:`distributions-basic-stat.py ` .. literalinclude:: code/distributions-basic-stat.py :lines: 1-10 Output:: feature   min   max   avg sepal length 4.300 7.900 5.843 sepal width 2.000 4.400 3.054 petal length 1.000 6.900 3.759 petal width 0.100 2.500 1.199 part of :download:`distributions-basic-stat.py ` .. literalinclude:: code/distributions-basic-stat.py :lines: 11- Output:: 5.84333467484
• ## docs/reference/rst/Orange.statistics.contingency.rst

 r10246 .. py:currentmodule::Orange.statistics.contingency .. py:currentmodule:: Orange.statistics.contingency .. index:: Contingency table ================= Contingency table ================= =================================== Contingency table (``contingency``) =================================== Contingency table contains conditional distributions. Unless explicitly
• ## docs/reference/rst/Orange.statistics.distribution.rst

 r10372 .. index:: Distributions ============= Distributions ============= ================================ Distributions (``distribution``) ================================ :obj:`Distribution` and derived classes store empirical
Note: See TracChangeset for help on using the changeset viewer.