I am trying to test whether two samples have the same distribution by using cramervonmises_2samp, in Juypter notebook, but I got this error "module 'scipy.stats' has no attribute 'cramervonmises_2samp'" when trying the example on page of scipy.stats.cramervonmises_2samp
import numpy as np
from scipy import stats
rng = np.random.default_rng()
x = stats.norm.rvs(size=100, random_state=rng)
y = stats.norm.rvs(size=70, random_state=rng)
res = stats.cramervonmises_2samp(x, y)
res.statistic, res.pvalue
Any suggestions ? Many thanks
I copy and paste the code of example in notebook, but it keeps showing the error.