French
Languages
English
Bengali
French
German
Japanese
Korean
Portuguese
Spanish
Tamil

qiskit.result.sampled_expectation_value

sampled_expectation_value(dist, oper)[source]

Computes expectation value from a sampled distribution

Note that passing a raw dict requires bit-string keys.

Paramètres
Renvoie

The expectation value

Type renvoyé

float

Lève

QiskitError – if the input distribution or operator is an invalid type