# qiskit.result.QuasiDistribution.nearest_probability_distribution¶

QuasiDistribution.nearest_probability_distribution(return_distance=False)[Quellcode]

Takes a quasiprobability distribution and maps it to the closest probability distribution as defined by the L2-norm.

Parameter

return_distance (bool) – Return the L2 distance between distributions.

Rückgabe

Nearest probability distribution. float: Euclidean (L2) distance of distributions.

Rückgabetyp

ProbDistribution

Notes

Method from Smolin et al., Phys. Rev. Lett. 108, 070502 (2012).