2

pivottablejs does not display any result in the jupyter notebook. Clicking on the hyperlink(pop out), displays an empty page.

from pivottablejs import pivot_ui
from IPython.display import IFrame
from IPython.core.display import display

import pandas as pd
df = pd.read_csv('sample.csv',encoding='utf-8')

enter image description here

Hackerds
  • 1,195
  • 2
  • 16
  • 34

1 Answers1

1

See this soloution (on https://github.com/nicolaskruchten/pivottable/issues/1269) that worked for me.

Hi, I did not find a workaround to use pivottable on vscode. But, if you open the pivottablejs.html that is generated into your folder in a web browser, you're able to use it normally.

This is my code that worked. First, I defined my path and saved an HTML file. Then I opened this html file in chrome, and it worked well.

#!pip install pivottablejs
from pivottablejs import pivot_ui
pivot_ui(df, outfile_path=r"D:\XXXXXX\pivot.html")