qiskit.aqua.operators.expectations.CVaRExpectation.compute_variance¶
-
CVaRExpectation.
compute_variance
(exp_op)[source]¶ Returns the variance of the CVaR calculation
- Parameters
exp_op (
OperatorBase
) – The operator whose evaluation yields an expectation of some StateFn against a diagonal observable.- Return type
Union
[list
,float
]- Returns
- The variance of the CVaR estimate corresponding to the converted
exp_op.
- Raises
ValueError – If the exp_op does not correspond to an expectation value.