<spanid="pyfts-models-ensemble-ensemble-module"></span><h2>pyFTS.models.ensemble.ensemble module<aclass="headerlink"href="#module-pyFTS.models.ensemble.ensemble"title="Permalink to this headline">¶</a></h2>
<p>EnsembleFTS wraps several FTS methods to ensemble their forecasts, providing point,
interval and probabilistic forecasting.</p>
<p>Silva, P. C. L et al. Probabilistic Forecasting with Seasonal Ensemble Fuzzy Time-Series
XIII Brazilian Congress on Computational Intelligence, 2017. Rio de Janeiro, Brazil.</p>
<emclass="property">class </em><codeclass="sig-prename descclassname">pyFTS.models.ensemble.ensemble.</code><codeclass="sig-name descname">AllMethodEnsembleFTS</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#AllMethodEnsembleFTS"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.AllMethodEnsembleFTS"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">set_transformations</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">model</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#AllMethodEnsembleFTS.set_transformations"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.AllMethodEnsembleFTS.set_transformations"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">train</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#AllMethodEnsembleFTS.train"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.AllMethodEnsembleFTS.train"title="Permalink to this definition">¶</a></dt>
<dd><p>Method specific parameter fitting</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– training time series data</p></li>
<li><p><strong>kwargs</strong>– Method specific parameters</p></li>
<emclass="property">class </em><codeclass="sig-prename descclassname">pyFTS.models.ensemble.ensemble.</code><codeclass="sig-name descname">EnsembleFTS</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">alpha</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.alpha"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">append_model</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">model</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.append_model"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.append_model"title="Permalink to this definition">¶</a></dt>
<dd><p>Append a new trained model to the ensemble</p>
<codeclass="sig-name descname">forecast</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.forecast"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.forecast"title="Permalink to this definition">¶</a></dt>
<dd><p>Point forecast one step ahead</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– time series data with the minimal length equal to the max_lag of the model</p></li>
<li><p><strong>kwargs</strong>– model specific parameters</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p>a list with the forecasted values</p>
<codeclass="sig-name descname">forecast_ahead_distribution</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="n">steps</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.forecast_ahead_distribution"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.forecast_ahead_distribution"title="Permalink to this definition">¶</a></dt>
<dd><p>Probabilistic forecast from 1 to H steps ahead, where H is given by the steps parameter</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– time series data with the minimal length equal to the max_lag of the model</p></li>
<li><p><strong>steps</strong>– the number of steps ahead to forecast</p></li>
<li><p><strong>start_at</strong>– in the multi step forecasting, the index of the data where to start forecasting (default: 0)</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p>a list with the forecasted Probability Distributions</p>
<codeclass="sig-name descname">forecast_ahead_interval</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="n">steps</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.forecast_ahead_interval"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.forecast_ahead_interval"title="Permalink to this definition">¶</a></dt>
<dd><p>Interval forecast from 1 to H steps ahead, where H is given by the steps parameter</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– time series data with the minimal length equal to the max_lag of the model</p></li>
<li><p><strong>steps</strong>– the number of steps ahead to forecast</p></li>
<li><p><strong>start_at</strong>– in the multi step forecasting, the index of the data where to start forecasting (default: 0)</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p>a list with the forecasted intervals</p>
<codeclass="sig-name descname">forecast_distribution</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.forecast_distribution"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.forecast_distribution"title="Permalink to this definition">¶</a></dt>
<dd><p>Probabilistic forecast one step ahead</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– time series data with the minimal length equal to the max_lag of the model</p></li>
<li><p><strong>kwargs</strong>– model specific parameters</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p>a list with probabilistic.ProbabilityDistribution objects representing the forecasted Probability Distributions</p>
<codeclass="sig-name descname">forecast_interval</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.forecast_interval"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.forecast_interval"title="Permalink to this definition">¶</a></dt>
<dd><p>Interval forecast one step ahead</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– time series data with the minimal length equal to the max_lag of the model</p></li>
<li><p><strong>kwargs</strong>– model specific parameters</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p>a list with the prediction intervals</p>
<codeclass="sig-name descname">get_UoD</code><spanclass="sig-paren">(</span><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.get_UoD"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.get_UoD"title="Permalink to this definition">¶</a></dt>
<dd><p>Returns the interval of the known bounds of the universe of discourse (UoD), i. e.,
the known minimum and maximum values of the time series.</p>
<dlclass="field-list simple">
<dtclass="field-odd">Returns</dt>
<ddclass="field-odd"><p>A set with the lower and the upper bounds of the UoD</p>
<codeclass="sig-name descname">get_distribution_interquantile</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">forecasts</span></em>, <emclass="sig-param"><spanclass="n">alpha</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.get_distribution_interquantile"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.get_distribution_interquantile"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">get_interval</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">forecasts</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.get_interval"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.get_interval"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">get_models_forecasts</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.get_models_forecasts"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.get_models_forecasts"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">get_point</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">forecasts</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.get_point"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.get_point"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">interval_method</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.interval_method"title="Permalink to this definition">¶</a></dt>
<dd><p>The method used to mix the several model’s forecasts into a interval forecast. Options: quantile, extremum, normal</p>
<codeclass="sig-name descname">models</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.models"title="Permalink to this definition">¶</a></dt>
<dd><p>A list of FTS models, the ensemble components</p>
<codeclass="sig-name descname">parameters</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.parameters"title="Permalink to this definition">¶</a></dt>
<dd><p>A list with the parameters for each component model</p>
<codeclass="sig-name descname">point_method</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.point_method"title="Permalink to this definition">¶</a></dt>
<dd><p>The method used to mix the several model’s forecasts into a unique point forecast. Options: mean, median, quantile, exponential</p>
<codeclass="sig-name descname">train</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#EnsembleFTS.train"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.EnsembleFTS.train"title="Permalink to this definition">¶</a></dt>
<dd><p>Method specific parameter fitting</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– training time series data</p></li>
<li><p><strong>kwargs</strong>– Method specific parameters</p></li>
<emclass="property">class </em><codeclass="sig-prename descclassname">pyFTS.models.ensemble.ensemble.</code><codeclass="sig-name descname">SimpleEnsembleFTS</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#SimpleEnsembleFTS"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.SimpleEnsembleFTS"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">method</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.SimpleEnsembleFTS.method"title="Permalink to this definition">¶</a></dt>
<dd><p>FTS method class that will be used on internal models</p>
<codeclass="sig-name descname">orders</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.SimpleEnsembleFTS.orders"title="Permalink to this definition">¶</a></dt>
<dd><p>Possible variations of order on internal models</p>
<codeclass="sig-name descname">partitioner_method</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.SimpleEnsembleFTS.partitioner_method"title="Permalink to this definition">¶</a></dt>
<dd><p>UoD partitioner class that will be used on internal methods</p>
<codeclass="sig-name descname">partitions</code><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.SimpleEnsembleFTS.partitions"title="Permalink to this definition">¶</a></dt>
<dd><p>Possible variations of number of partitions on internal models</p>
<codeclass="sig-name descname">train</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#SimpleEnsembleFTS.train"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.SimpleEnsembleFTS.train"title="Permalink to this definition">¶</a></dt>
<dd><p>Method specific parameter fitting</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– training time series data</p></li>
<li><p><strong>kwargs</strong>– Method specific parameters</p></li>
</ul>
</dd>
</dl>
</dd></dl>
</dd></dl>
<dlclass="py function">
<dtid="pyFTS.models.ensemble.ensemble.sampler">
<codeclass="sig-prename descclassname">pyFTS.models.ensemble.ensemble.</code><codeclass="sig-name descname">sampler</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="n">quantiles</span></em>, <emclass="sig-param"><spanclass="n">bounds</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/ensemble.html#sampler"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.ensemble.sampler"title="Permalink to this definition">¶</a></dt>
<spanid="pyfts-models-ensemble-multiseasonal-module"></span><h2>pyFTS.models.ensemble.multiseasonal module<aclass="headerlink"href="#module-pyFTS.models.ensemble.multiseasonal"title="Permalink to this headline">¶</a></h2>
<p>Silva, P. C. L et al. Probabilistic Forecasting with Seasonal Ensemble Fuzzy Time-Series
XIII Brazilian Congress on Computational Intelligence, 2017. Rio de Janeiro, Brazil.</p>
<emclass="property">class </em><codeclass="sig-prename descclassname">pyFTS.models.ensemble.multiseasonal.</code><codeclass="sig-name descname">SeasonalEnsembleFTS</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">name</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/multiseasonal.html#SeasonalEnsembleFTS"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.multiseasonal.SeasonalEnsembleFTS"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">forecast_distribution</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/multiseasonal.html#SeasonalEnsembleFTS.forecast_distribution"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.multiseasonal.SeasonalEnsembleFTS.forecast_distribution"title="Permalink to this definition">¶</a></dt>
<dd><p>Probabilistic forecast one step ahead</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– time series data with the minimal length equal to the max_lag of the model</p></li>
<li><p><strong>kwargs</strong>– model specific parameters</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p>a list with probabilistic.ProbabilityDistribution objects representing the forecasted Probability Distributions</p>
<codeclass="sig-name descname">train</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em>, <emclass="sig-param"><spanclass="o">**</span><spanclass="n">kwargs</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/multiseasonal.html#SeasonalEnsembleFTS.train"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.multiseasonal.SeasonalEnsembleFTS.train"title="Permalink to this definition">¶</a></dt>
<dd><p>Method specific parameter fitting</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>data</strong>– training time series data</p></li>
<li><p><strong>kwargs</strong>– Method specific parameters</p></li>
<codeclass="sig-name descname">update_uod</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">data</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/multiseasonal.html#SeasonalEnsembleFTS.update_uod"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.multiseasonal.SeasonalEnsembleFTS.update_uod"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-prename descclassname">pyFTS.models.ensemble.multiseasonal.</code><codeclass="sig-name descname">train_individual_model</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">partitioner</span></em>, <emclass="sig-param"><spanclass="n">train_data</span></em>, <emclass="sig-param"><spanclass="n">indexer</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="_modules/pyFTS/models/ensemble/multiseasonal.html#train_individual_model"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#pyFTS.models.ensemble.multiseasonal.train_individual_model"title="Permalink to this definition">¶</a></dt>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-pyFTS.models.ensemble"title="Permalink to this headline">¶</a></h2>