python - 统计模型 ARIMA.fit : Hide output

标签 python statsmodels scientific-computing

似乎每当我运行 ARIMA.fit() 时,我总是从卡尔曼滤波器获得标准输出:

## -- End pasted text --
RUNNING THE L-BFGS-B CODE

           * * *

Machine precision = 2.220D-16
 N =            1     M =           12
 This problem is unconstrained.

At X0         0 variables are exactly at the bounds

At iterate    0    f=  5.60459D-01    |proj g|=  2.22045D-08

           * * *

Tit   = total number of iterations
Tnf   = total number of function evaluations
Tnint = total number of segments explored during Cauchy searches
Skip  = number of BFGS updates skipped
Nact  = number of active bounds at final generalized Cauchy point
Projg = norm of the final projected gradient
F     = final function value

           * * *

   N    Tit     Tnf  Tnint  Skip  Nact     Projg        F
    1      1      3      1     0     0   0.000D+00   5.605D-01
  F =  0.560459405131994

CONVERGENCE: NORM_OF_PROJECTED_GRADIENT_<=_PGTOL

 Cauchy                time 0.000E+00 seconds.
 Subspace minimization time 0.000E+00 seconds.
 Line search           time 0.000E+00 seconds.

 Total User time 0.000E+00 seconds.

似乎没有一个明显的参数可以传递给 fit 来隐藏这个输出。如何隐藏此输出?

最佳答案

来自@user333700 的评论,使用:

arima.fit(disp=0)

documentation (对于版本 0.7.0.dev-c8e980d)说:

disp : bool, optional

If True, convergence information is printed. For the default l_bfgs_b solver, disp controls the frequency of the output during the iterations. disp < 0 means no output in this case.

关于python - 统计模型 ARIMA.fit : Hide output,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31884410/

相关文章:

python - 如何在 PySpark 中将两列堆叠成一列?

python - 计算一系列 numpy ndarrays 的外积

c++ - 我需要一些建议来为我的模拟找到足够的算法

python - python 会缓存实例变量还是每次调用它们时都会计算它们

python - For 循环求值顺序

python - 如何在逻辑回归中使用权重

python - statsmodel线性回归(ols)的稳健性问题 - Python

python - 无法理解和使用 Statsmodels 的 SARIMAX `conf_int()` 输出

python - 如何从 `sympy.solve` 结果中消除负解?

python - EC2上的Python脚本返回错误的签名类型错误