/%python
import numpy as np
size = 100
np.random.seed(0)
x_data = np.arange(size)
y_data = np.cumsum(np.random.randn(size) * 100.0)
from bqplot import pyplot as plt
plt.figure(title='My First Plot')
plt.plot(x_data,x_data)
returns error
e: bad argument type for built-in operation
[1] /Users/dianeodonoghue/q/p.q:13: .p.e:{$["def"~3#x;$[x[3]in"<*>";ei 3;eo];"class"~5#x;$[x[5]in"*>";ei 5;eo];eo]x}
^
[0] p)plt.plot(x_data,x_data)
^
Issue arises at line plt.plot(x_data,x_data) when initalising the scales for the interactive plot in ipywidgets, so changing the input data will not fix the issue:
/%python
from bqplot import marks,scales
dict={'x':scales.LinearScale(),
'y':scales.LinearScale()}
marks.Lines(scales=dict)
evaluation error:
e: bad argument type for built-in operation
[1] /Users/dianeodonoghue/q/p.q:13: .p.e:{$["def"~3#x;$[x[3]in"<*>";ei 3;eo];"class"~5#x;$[x[5]in"*>";ei 5;eo];eo]x}
^
[0] p)marks.Lines(scales=dict)
Also, issue does not arise when running in a q terminal, only in a jupyter notebook.
ipywidgets issue raised:
returns error
Issue arises at line
plt.plot(x_data,x_data)
when initalising the scales for the interactive plot in ipywidgets, so changing the input data will not fix the issue:Also, issue does not arise when running in a q terminal, only in a jupyter notebook.