markfairbanks / tidypolars

Tidy interface to polars
http://tidypolars.readthedocs.io
MIT License
321 stars 10 forks source link

Name Error in to_pandas function #165

Closed fabifuu closed 2 years ago

fabifuu commented 2 years ago

When I try to convert Tibble into pandas data frame, I encountered name error. I use an example from your github README.md

df = tp.Tibble(x = range(5), y = range(3, 8), z = ['a', 'a', 'b', 'b', 'c'])
df
df = df.to_pandas()

Then name error happened:

NameError: name 'pa' is not defined

I have installed pandas and pyarrow

markfairbanks commented 2 years ago

Everything works fine when I run this. Did you restart your kernel after installing pyarrow/pandas?

You can also try running import pyarrow as pa and see if it works, but the code should work without you doing that.

Can you run this and let me know what version of polars you have?

import polars as pl
pl.__version__
markfairbanks commented 2 years ago

I’m going to close this for now since I can’t reproduce the issue.

If you keep running into problems let me know and we’ll see if we can get it figured out.