Ball
Ball copied to clipboard
Linux-AttributeError: module 'Ball._cball' has no attribute 'doubleArray_swiginit'
I successfully install the package in linux, but found the error while running the toy example provided in the code. Besides, I can successfully run the demo in windows.
The original code is as follows:
import Ball as ball import numpy as np import math
np.random.seed(2)
#%% both x, y are numeric vector n = 50 error = np.random.uniform(-0.3, 0.3, n) x = np.random.uniform(0, 4*math.pi, n) y = np.cos(x) + error a = ball.bcov_test(x, y)
The original log is as follows:
Traceback (most recent call last):
File "Ball_test.py", line 19, in
Look forward to your reply. Thanks.
I think this problem might come from the setting of SWIG in Linux, and I need some time to fix it. I suggest to use rpy2 (https://rpy2.github.io/doc/v2.9.x/html/introduction.html) to call R command for bcov.test.