endangeredoxen / fivecentplots

A Python plotting analgesic
https://endangeredoxen.github.io/fivecentplots
11 stars 6 forks source link

FCP version 0.5.0 | module 'fivecentplots.data' has no attribute 'XY' #39

Closed hgaonkar closed 1 year ago

hgaonkar commented 2 years ago

python version 3.9.11 fcp version 0.5.0 Command used : fcp.plot(image_loc_df, x='EIT [ms]', y='AG')

Error: Unexpected exception formatting exception. Falling back to standard exception Traceback (most recent call last): File "C:\Users\TEIV-1\miniconda3\envs\imagecrunch\lib\site-packages\IPython\core\interactiveshell.py", line 3369, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "C:\Users\TEIV-1\AppData\Local\Temp\ipykernel_15820\2284732138.py", line 1, in <cell line: 1> fcp.plot(image_loc_df, x='EIT [ms]', y='AG') File "C:\Users\TEIV-1\miniconda3\envs\imagecrunch\lib\site-packages\fivecentplots\fcp.py", line 272, in plot return plotter(data.XY, **dfkwarg(args, kwargs)) AttributeError: module 'fivecentplots.data' has no attribute 'XY'

endangeredoxen commented 2 years ago

Can you please pull the latest updates to 0.5.0 branch and try again?

hgaonkar commented 2 years ago

Exact same error as before. matplotlib version 3.5.1 fivecentplot version 0.5.0 installed with

pip install https://github.com/endangeredoxen/fivecentplots/archive/refs/heads/0.5.0.zip

File ~\miniconda3\envs\imagecrunch\lib\site-packages\fivecentplots\fcp.py:279, in plot(*args, *kwargs) 274 def plot(args, kwargs): 275 """ 276 XY plot 277 """ --> 279 return plotter(data.XY, dfkwarg(args, kwargs))

AttributeError: module 'fivecentplots.data' has no attribute 'XY'

endangeredoxen commented 2 years ago

I believe you have something wrong in your install or path. Please check in your install directory to confirm if you have data --> xy.py. I just built a new env with mpl 3.5.1 and fcp 0.5.0 and I cannot reproduce your error. You can also check fcp.__version__ to make sure you are pointing to 0.5.0.

Also note that I haven't tested 3.3.1 so there could be other issues you will face (but that isn't the cause of the error message you are reporting)