ydata-profiling icon indicating copy to clipboard operation
ydata-profiling copied to clipboard

.to_json and ._render_json do not return data under "Toggle details" tab

Open VikrantMN26 opened this issue 5 years ago • 2 comments

We use both the html report and the json output in our projects. However, a few things present in the html report seem to be missing in the json output. Specifically, the data from the "Toggle Details" tab under every variable is missing in the json output.

To Reproduce import pandas as pd from pandas_profiling import ProfileReport

def test_issueXXX(): df = pd.read_csv(r'',encoding="unicode_escape") prof = ProfileReport(df) return prof._render_json()

Version information: Python version - 3.7.9 pandas-profiling version : 2.9.0

VikrantMN26 avatar Oct 28 '20 13:10 VikrantMN26

I believe this part of data is in the json (maybe wrong)

Since the json structure is kind of complex, read this function may help you understand it https://github.com/pandas-profiling/pandas-profiling/blob/87d964c1e5a20461002c27a2861f7ea1ba742c93/src/pandas_profiling/model/describe.py#L24

loopyme avatar Nov 18 '20 18:11 loopyme

@VikrantMN26 We've changed the json respresentation a bit (still could be simplified more even). If you're still encountering this issue, could you please give an example of a specific field missing for a given dataset (for instance from the examples section)?

sbrugman avatar Jan 07 '21 17:01 sbrugman

Although some improvements can be made in regard to the json schema, all fields under the toggle details tab are currently available under the variables key in the json, although some may be under different names. In case you find any specific field missing, please add an example and reopen this issue or create a new one

alexbarros avatar May 23 '23 15:05 alexbarros