pandas_profiling.profile_report.ProfileReport

class pandas_profiling.profile_report.ProfileReport(df=None, minimal=False, explorative=False, sensitive=False, dark_mode=False, orange_mode=False, sample=None, config_file=None, lazy=True, typeset=None, summarizer=None, config=None, **kwargs)[source]

Generate a profile report from a Dataset stored as a pandas DataFrame.

Used as is, it will output its content as an HTML report in a Jupyter notebook.

Generate a ProfileReport based on a pandas DataFrame

Parameters
  • df (Optional[DataFrame]) – the pandas DataFrame

  • minimal (bool) – minimal mode is a default configuration with minimal computation

  • config_file (Union[Path, str, None]) – a config file (.yml), mutually exclusive with minimal

  • lazy (bool) – compute when needed

  • sample (Optional[dict]) – optional dict(name=”Sample title”, caption=”Caption”, data=pd.DataFrame())

  • typeset (Optional[VisionsTypeset]) – optional user typeset to use for type inference

  • summarizer (Optional[BaseSummarizer]) – optional user summarizer to generate custom summary output

  • **kwargs – other arguments, for valid arguments, check the default configuration file.

__init__(df=None, minimal=False, explorative=False, sensitive=False, dark_mode=False, orange_mode=False, sample=None, config_file=None, lazy=True, typeset=None, summarizer=None, config=None, **kwargs)[source]

Generate a ProfileReport based on a pandas DataFrame

Parameters
  • df (Optional[DataFrame]) – the pandas DataFrame

  • minimal (bool) – minimal mode is a default configuration with minimal computation

  • config_file (Union[Path, str, None]) – a config file (.yml), mutually exclusive with minimal

  • lazy (bool) – compute when needed

  • sample (Optional[dict]) – optional dict(name=”Sample title”, caption=”Caption”, data=pd.DataFrame())

  • typeset (Optional[VisionsTypeset]) – optional user typeset to use for type inference

  • summarizer (Optional[BaseSummarizer]) – optional user summarizer to generate custom summary output

  • **kwargs – other arguments, for valid arguments, check the default configuration file.

Methods

__init__([df, minimal, explorative, …])

Generate a ProfileReport based on a pandas DataFrame

dump(output_file)

Dump ProfileReport to file

dumps()

Serialize ProfileReport and return bytes for reproducing ProfileReport or Caching.

get_description()

Return the description (a raw statistical summary) of the dataset.

get_duplicates()

Get duplicate rows and counts based on the configuration

get_rejected_variables()

Get variables that are rejected for analysis (e.g.

get_sample()

Get head/tail samples based on the configuration

invalidate_cache([subset])

Invalidate report cache.

load(load_file)

Load ProfileReport from file

loads(data)

Deserialize the serialized report

preprocess(df)

Preprocess the dataframe

to_expectation_suite([suite_name, …])

All parameters default to True to make it easier to access the full functionality of Great Expectations out of the box. :type suite_name: Optional[str] :param suite_name: The name of your expectation suite :type data_context: Optional[Any] :param data_context: A user-specified data context :type save_suite: bool :param save_suite: Boolean to determine whether to save the suite to .json as part of the method :type run_validation: bool :param run_validation: Boolean to determine whether to run validation as part of the method :type build_data_docs: bool :param build_data_docs: Boolean to determine whether to build data docs, save the .html file, and open data docs in your browser :type handler: Optional[Handler] :param handler: The handler to use for building expectation.

to_file(output_file[, silent])

Write the report to a file.

to_html()

Generate and return complete template as lengthy string

to_json()

Represent the ProfileReport as a JSON string

to_notebook_iframe()

Used to output the HTML representation to a Jupyter notebook.

to_widgets()

The ipython notebook widgets user interface.

Attributes

config

description_set

rtype

Dict[str, Any]

df

df_hash

rtype

Optional[str]

html

rtype

str

json

rtype

str

report

rtype

Root

summarizer

rtype

BaseSummarizer

typeset

rtype

Optional[VisionsTypeset]

widgets

rtype

Renderable