{"id":13419056,"url":"https://github.com/dexplo/dexplot","last_synced_at":"2026-03-11T03:31:07.171Z","repository":{"id":50494378,"uuid":"145591060","full_name":"dexplo/dexplot","owner":"dexplo","description":"Simple plotting library that wraps Matplotlib and integrated with DataFrames","archived":false,"fork":false,"pushed_at":"2020-11-04T12:52:30.000Z","size":10207,"stargazers_count":232,"open_issues_count":2,"forks_count":9,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-11-07T02:16:32.647Z","etag":null,"topics":["data-visualization","matplotlib","pandas","plotly","python"],"latest_commit_sha":null,"homepage":"https://dexplo.org/dexplot","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dexplo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"custom":["https://dunderdata.com"]}},"created_at":"2018-08-21T16:32:10.000Z","updated_at":"2025-10-28T17:51:29.000Z","dependencies_parsed_at":"2022-09-03T08:52:02.320Z","dependency_job_id":null,"html_url":"https://github.com/dexplo/dexplot","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dexplo/dexplot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dexplo%2Fdexplot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dexplo%2Fdexplot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dexplo%2Fdexplot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dexplo%2Fdexplot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dexplo","download_url":"https://codeload.github.com/dexplo/dexplot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dexplo%2Fdexplot/sbom","scorecard":{"id":338762,"data":{"date":"2025-08-11","repo":{"name":"github.com/dexplo/dexplot","commit":"efe6d799e4a32381e487fa6d654f15970a5bb204"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.4,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/python-package.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/dexplo/dexplot/python-package.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/dexplo/dexplot/python-package.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:30","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:31","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: BSD 3-Clause \"New\" or \"Revised\" License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-18T05:18:19.889Z","repository_id":50494378,"created_at":"2025-08-18T05:18:19.889Z","updated_at":"2025-08-18T05:18:19.889Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30369379,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T21:41:54.280Z","status":"online","status_checked_at":"2026-03-11T02:00:07.027Z","response_time":84,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-visualization","matplotlib","pandas","plotly","python"],"created_at":"2024-07-30T22:01:10.703Z","updated_at":"2026-03-11T03:31:07.147Z","avatar_url":"https://github.com/dexplo.png","language":"Jupyter Notebook","readme":"# Dexplot\n\n[![](https://img.shields.io/pypi/v/dexplot)](https://pypi.org/project/dexplot)\n[![PyPI - License](https://img.shields.io/pypi/l/dexplot)](LICENSE)\n\nDexplot is a Python library for delivering beautiful data visualizations with a simple and intuitive user experience.\n\n## Goals\n\nThe primary goals for dexplot are:\n\n* Maintain a very consistent API with as few functions as necessary to make the desired statistical plots\n* Allow the user tremendous power without using matplotlib\n\n\n## Installation\n\n`pip install dexplot`\n\n## Built for long and wide data\n\nDexplot is primarily built for long data, which is a form of data where each row represents a single observation and each column represents a distinct quantity. It is often referred to as \"tidy\" data. Here, we have some long data.\n\n![](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/long.png)\n\nDexplot also has the ability to handle wide data, where multiple columns may contain values that represent the same kind of quantity. The same data above has been aggregated to show the mean for each combination of neighborhood and property type. It is now wide data as each column contains the same quantity (price).\n\n![](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/wide.png)\n\n## Usage\n\nDexplot provides a small number of powerful functions that all work similarly. Most plotting functions have the following signature:\n\n```python\ndxp.plotting_func(x, y, data, aggfunc, split, row, col, orientation, ...)\n```\n\n* `x` - Column name along the x-axis\n* `y` - Column name the y-axis\n* `data` - Pandas DataFrame\n* `aggfunc` - String of pandas aggregation function, 'min', 'max', 'mean', etc...\n* `split` - Column name to split data into distinct groups\n* `row` - Column name to split data into distinct subplots row-wise\n* `col` - Column name to split data into distinct subplots column-wise\n* `orientation` - Either vertical (`'v'`) or horizontal (`'h'`). Default for most plots is vertical.\n\nWhen `aggfunc` is provided, `x` will be the grouping variable and `y` will be aggregated when vertical and vice-versa when horizontal. The best way to learn how to use dexplot is with the examples below.\n\n## Families of plots\n\nThere are two primary families of plots, **aggregation** and **distribution**. Aggregation plots take a sequence of values and return a **single** value using the function provided to `aggfunc` to do so. Distribution plots take a sequence of values and depict the shape of the distribution in some manner.\n\n* Aggregation\n    * bar\n    * line\n    * scatter\n    * count\n* Distribution\n    * box\n    * violin\n    * hist\n    * kde\n\n## Comparison with Seaborn\n\nIf you have used the seaborn library, then you should notice a lot of similarities. Much of dexplot was inspired by Seaborn. Below is a list of the extra features in dexplot not found in seaborn\n\n* Ability to graph relative frequency and normalize over any number of variables\n* No need for multiple functions to do the same thing (far fewer public functions)\n* Ability to make grids with a single function instead of having to use a higher level function like `catplot`\n* Pandas `groupby` methods available as strings\n* Ability to sort by values\n* Ability to sort x/y labels lexicographically\n* Ability to select most/least frequent groups\n* x/y labels are wrapped so that they don't overlap\n* Figure size (plus several other options) and available to change without using matplotlib\n* A matplotlib figure object is returned\n\n## Examples\n\nMost of the examples below use long data.\n\n## Aggregating plots - bar, line and scatter\n\nWe'll begin by covering the plots that **aggregate**. An aggregation is defined as a function that summarizes a sequence of numbers with a single value. The examples come from the Airbnb dataset, which contains many property rental listings from the Washington D.C. area.\n\n\n```python\nimport dexplot as dxp\nimport pandas as pd\nairbnb = dxp.load_dataset('airbnb')\nairbnb.head()\n```\n\n\u003cdiv\u003e\n\u003ctable border=\"1\" class=\"dataframe\"\u003e\n  \u003cthead style=\"border-bottom:1px solid black; vertical-align:bottom;\"\u003e\n    \u003ctr style=\"text-align: right;\"\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth style=\"color:red;\"\u003eneighborhood\u003c/th\u003e\n      \u003cth\u003eproperty_type\u003c/th\u003e\n      \u003cth\u003eaccommodates\u003c/th\u003e\n      \u003cth\u003ebathrooms\u003c/th\u003e\n      \u003cth\u003ebedrooms\u003c/th\u003e\n      \u003cth\u003eprice\u003c/th\u003e\n      \u003cth\u003ecleaning_fee\u003c/th\u003e\n      \u003cth\u003erating\u003c/th\u003e\n      \u003cth\u003esuperhost\u003c/th\u003e\n      \u003cth\u003eresponse_time\u003c/th\u003e\n      \u003cth\u003elatitude\u003c/th\u003e\n      \u003cth\u003elongitude\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003cth\u003e0\u003c/th\u003e\n      \u003ctd\u003eShaw\u003c/td\u003e\n      \u003ctd\u003eTownhouse\u003c/td\u003e\n      \u003ctd\u003e16\u003c/td\u003e\n      \u003ctd\u003e3.5\u003c/td\u003e\n      \u003ctd\u003e4\u003c/td\u003e\n      \u003ctd\u003e433\u003c/td\u003e\n      \u003ctd\u003e250\u003c/td\u003e\n      \u003ctd\u003e95.0\u003c/td\u003e\n      \u003ctd\u003eNo\u003c/td\u003e\n      \u003ctd\u003ewithin an hour\u003c/td\u003e\n      \u003ctd\u003e38.90982\u003c/td\u003e\n      \u003ctd\u003e-77.02016\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e1\u003c/th\u003e\n      \u003ctd\u003eBrightwood Park\u003c/td\u003e\n      \u003ctd\u003eTownhouse\u003c/td\u003e\n      \u003ctd\u003e4\u003c/td\u003e\n      \u003ctd\u003e3.5\u003c/td\u003e\n      \u003ctd\u003e4\u003c/td\u003e\n      \u003ctd\u003e154\u003c/td\u003e\n      \u003ctd\u003e50\u003c/td\u003e\n      \u003ctd\u003e97.0\u003c/td\u003e\n      \u003ctd\u003eNo\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e38.95888\u003c/td\u003e\n      \u003ctd\u003e-77.02554\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e2\u003c/th\u003e\n      \u003ctd\u003eCapitol Hill\u003c/td\u003e\n      \u003ctd\u003eHouse\u003c/td\u003e\n      \u003ctd\u003e2\u003c/td\u003e\n      \u003ctd\u003e1.5\u003c/td\u003e\n      \u003ctd\u003e1\u003c/td\u003e\n      \u003ctd\u003e83\u003c/td\u003e\n      \u003ctd\u003e35\u003c/td\u003e\n      \u003ctd\u003e97.0\u003c/td\u003e\n      \u003ctd\u003eYes\u003c/td\u003e\n      \u003ctd\u003ewithin an hour\u003c/td\u003e\n      \u003ctd\u003e38.88791\u003c/td\u003e\n      \u003ctd\u003e-76.99668\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e3\u003c/th\u003e\n      \u003ctd\u003eShaw\u003c/td\u003e\n      \u003ctd\u003eHouse\u003c/td\u003e\n      \u003ctd\u003e2\u003c/td\u003e\n      \u003ctd\u003e2.5\u003c/td\u003e\n      \u003ctd\u003e1\u003c/td\u003e\n      \u003ctd\u003e475\u003c/td\u003e\n      \u003ctd\u003e0\u003c/td\u003e\n      \u003ctd\u003e98.0\u003c/td\u003e\n      \u003ctd\u003eNo\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e38.91331\u003c/td\u003e\n      \u003ctd\u003e-77.02436\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e4\u003c/th\u003e\n      \u003ctd\u003eKalorama Heights\u003c/td\u003e\n      \u003ctd\u003eApartment\u003c/td\u003e\n      \u003ctd\u003e3\u003c/td\u003e\n      \u003ctd\u003e1.0\u003c/td\u003e\n      \u003ctd\u003e1\u003c/td\u003e\n      \u003ctd\u003e118\u003c/td\u003e\n      \u003ctd\u003e15\u003c/td\u003e\n      \u003ctd\u003e91.0\u003c/td\u003e\n      \u003ctd\u003eNo\u003c/td\u003e\n      \u003ctd\u003ewithin an hour\u003c/td\u003e\n      \u003ctd\u003e38.91933\u003c/td\u003e\n      \u003ctd\u003e-77.04124\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\u003c/div\u003e\n\n\n\nThere are more than 4,000 listings in our dataset. We will use bar charts to aggregate the data.\n\n\n```python\nairbnb.shape\n```\n\n\n\n\n    (4581, 12)\n\n\n\n### Vertical bar charts\n\nIn order to performa an aggregation, you must supply a value for `aggfunc`. Here, we find the median price per neighborhood. Notice that the column names automatically wrap.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_7_0.png)\n\n\n\nLine and scatter plots can be created with the same command, just substituting the name of the function. They both are not good choices for the visualization since the grouping variable (neighborhood) has no meaningful order.\n\n\n```python\ndxp.line(x='neighborhood', y='price', data=airbnb, aggfunc='median')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_9_0.png)\n\n\n\n\n```python\ndxp.scatter(x='neighborhood', y='price', data=airbnb, aggfunc='median')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_10_0.png)\n\n\n\n### Components of the groupby aggregation\n\nAnytime the `aggfunc` parameter is set, you have performed a groupby aggregation, which always consists of three components:\n\n* Grouping column - unique values of this column form independent groups (neighborhood)\n* Aggregating column - the column that will get summarized with a single value (price)\n* Aggregating function - a function that returns a single value (median)\n\nThe general format for doing this in pandas is:\n\n```python\ndf.groupby('grouping column').agg({'aggregating column': 'aggregating function'})\n```\n\nSpecifically, the following code is executed within dexplot.\n\n\n```python\nairbnb.groupby('neighborhood').agg({'price': 'median'})\n```\n\n\n\n\n\u003cdiv\u003e\n\u003ctable border=\"1\" class=\"dataframe\"\u003e\n  \u003cthead\u003e\n    \u003ctr style=\"text-align: right;\"\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003eprice\u003c/th\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eneighborhood\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003cth\u003eBrightwood Park\u003c/th\u003e\n      \u003ctd\u003e87.0\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eCapitol Hill\u003c/th\u003e\n      \u003ctd\u003e129.5\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eColumbia Heights\u003c/th\u003e\n      \u003ctd\u003e95.0\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eDupont Circle\u003c/th\u003e\n      \u003ctd\u003e125.0\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eEdgewood\u003c/th\u003e\n      \u003ctd\u003e100.0\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eKalorama Heights\u003c/th\u003e\n      \u003ctd\u003e118.0\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eShaw\u003c/th\u003e\n      \u003ctd\u003e133.5\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eUnion Station\u003c/th\u003e\n      \u003ctd\u003e120.0\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\u003c/div\u003e\n\n\n\n### Number and percent of missing values with  `'countna'` and `'percna'`\n\nIn addition to all the common aggregating functions, you can use the strings `'countna'` and `'percna'` to get the number and percentage of missing values per group.\n\n\n```python\ndxp.bar(x='neighborhood', y='response_time', data=airbnb, aggfunc='countna')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_14_0.png)\n\n\n\n### Sorting the bars by values\n\nBy default, the bars will be sorted by the grouping column (x-axis here) in alphabetical order. Use the `sort_values` parameter to sort the bars by value.\n\n* None - sort x/y axis labels alphabetically (default)\n* `asc` - sort values from least to greatest\n* `desc` - sort values from greatest to least\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', sort_values='asc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_16_0.png)\n\n\n\nHere, we sort the values from greatest to least.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', sort_values='desc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_18_0.png)\n\n\n\n### Specify order with `x_order`\n\nSpecify a specific order of the labels on the x-axis by passing a list of values to `x_order`. This can also act as a filter to limit the number of bars.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median',\n        x_order=['Dupont Circle', 'Edgewood', 'Union Station'])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_20_0.png)\n\n\n\nBy default, `x_order` and all of the `_order` parameters are set to `'asc'` by default, which will order them alphabetically. Use the string `'desc'` to sort in the opposite direction.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', x_order='desc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_22_0.png)\n\n\n\n### Filter for the neighborhoods with most/least frequency of occurrence\n\nYou can use `x_order` again to filter for the x-values that appear the most/least often by setting it to the string `'top n'` or `'bottom n'` where `n` is an integer. Here, we filter for the top 4 most frequently occurring neighborhoods. This option is useful when there are dozens of unique values in the grouping column.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median',\n        x_order='top 4')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_24_0.png)\n\n\n\nWe can verify that the four neighborhoods are the most common.\n\n\n```python\nairbnb['neighborhood'].value_counts()\n```\n\n\n\n\n    Columbia Heights    773\n    Union Station       713\n    Capitol Hill        654\n    Edgewood            610\n    Dupont Circle       549\n    Shaw                514\n    Brightwood Park     406\n    Kalorama Heights    362\n    Name: neighborhood, dtype: int64\n\n\n\n### Horizontal bars\n\nSet `orientation` to `'h'` for horizontal bars. When you do this, you'll need to switch `x` and `y` since the grouping column (neighborhood) will be along the y-axis and the aggregating column (price) will be along the x-axis.\n\n\n```python\ndxp.bar(x='price', y='neighborhood', data=airbnb, aggfunc='median', \n        orientation='h', sort_values='desc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_28_0.png)\n\n\n\nSwitching orientation is possible for most other plots.\n\n\n```python\ndxp.line(x='price', y='neighborhood', data=airbnb, aggfunc='median', orientation='h')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_30_0.png)\n\n\n\n### Split bars into groups\n\nYou can split each bar into further groups by setting the `split` parameter to another column.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', split='superhost')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_32_0.png)\n\n\n\nWe can use the `pivot_table` method to verify the results in pandas.\n\n\n```python\nairbnb.pivot_table(index='superhost', columns='neighborhood', \n                   values='price', aggfunc='median')\n```\n\n\n\n\n\u003cdiv\u003e\n\u003ctable border=\"1\" class=\"dataframe\"\u003e\n  \u003cthead\u003e\n    \u003ctr style=\"text-align: right;\"\u003e\n      \u003cth\u003eneighborhood\u003c/th\u003e\n      \u003cth\u003eBrightwood Park\u003c/th\u003e\n      \u003cth\u003eCapitol Hill\u003c/th\u003e\n      \u003cth\u003eColumbia Heights\u003c/th\u003e\n      \u003cth\u003eDupont Circle\u003c/th\u003e\n      \u003cth\u003eEdgewood\u003c/th\u003e\n      \u003cth\u003eKalorama Heights\u003c/th\u003e\n      \u003cth\u003eShaw\u003c/th\u003e\n      \u003cth\u003eUnion Station\u003c/th\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003esuperhost\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003cth\u003eNo\u003c/th\u003e\n      \u003ctd\u003e85.0\u003c/td\u003e\n      \u003ctd\u003e129.0\u003c/td\u003e\n      \u003ctd\u003e90.5\u003c/td\u003e\n      \u003ctd\u003e120.0\u003c/td\u003e\n      \u003ctd\u003e100.0\u003c/td\u003e\n      \u003ctd\u003e110.0\u003c/td\u003e\n      \u003ctd\u003e130.0\u003c/td\u003e\n      \u003ctd\u003e120.0\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eYes\u003c/th\u003e\n      \u003ctd\u003e90.0\u003c/td\u003e\n      \u003ctd\u003e130.0\u003c/td\u003e\n      \u003ctd\u003e103.0\u003c/td\u003e\n      \u003ctd\u003e135.0\u003c/td\u003e\n      \u003ctd\u003e100.0\u003c/td\u003e\n      \u003ctd\u003e124.0\u003c/td\u003e\n      \u003ctd\u003e135.0\u003c/td\u003e\n      \u003ctd\u003e125.0\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\u003c/div\u003e\n\n\n\nSet the order of the unique split values with `split_order`, which can also act as a filter.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', \n        split='superhost', split_order=['Yes', 'No'])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_36_0.png)\n\n\n\nLike all the `_order` parameters, `split_order` defaults to `'asc'` (alphabetical) order. Set it to `'desc'` for the opposite.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median',\n        split='property_type', split_order='desc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_38_0.png)\n\n\n\nFiltering for the most/least frequent split categories is possible.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', \n        split='property_type', split_order='bottom 2')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_40_0.png)\n\n\n\nVerifying that the least frequent property types are Townhouse and Condominium.\n\n\n```python\nairbnb['property_type'].value_counts()\n```\n\n\n\n\n    Apartment      2403\n    House           877\n    Townhouse       824\n    Condominium     477\n    Name: property_type, dtype: int64\n\n\n\n### Stacked bar charts\n\nStack all the split groups one on top of the other by setting `stacked` to `True`.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', \n        split='superhost', split_order=['Yes', 'No'], stacked=True)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_44_0.png)\n\n\n\n### Split into multiple plots\n\nIt's possible to split the data further into separate plots by the unique values in a different column with the `row` and `col` parameters. Here, each kind of `property_type` has its own plot.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', \n        split='superhost', col='property_type')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_46_0.png)\n\n\n\nIf there isn't room for all of the plots, set the `wrap` parameter to an integer to set the maximum number of plots per row/col. We also specify the `col_order` to be descending alphabetically.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', \n        split='superhost', col='property_type', wrap=2, col_order='desc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_48_0.png)\n\n\n\nUse `col_order` to both filter and set a specific order for the plots.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median',\n        split='superhost', col='property_type', col_order=['House', 'Condominium'])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_50_0.png)\n\n\n\nSplits can be made simultaneously along row and columns.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', split='superhost', \n        col='property_type', col_order=['House', 'Condominium', 'Apartment'],\n        row='bedrooms', row_order=[1, 2, 3])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_52_0.png)\n\n\n\nBy default, all axis limits are shared. Allow each plot to set its own limits by setting `sharex` and `sharey` to `False`.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, aggfunc='median', split='superhost', \n        col='property_type', col_order=['House', 'Condominium', 'Apartment'],\n        row='bedrooms', row_order=[1, 2, 3], sharey=False)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_54_0.png)\n\n\n\n### Set the width of each bar with `size`\n\nThe width (height when horizontal) of the bars is set with the `size` parameter. By default, this value is .9. Think of this number as the relative width of all the bars for a particular x/y value, where 1 is the distance between each x/y value.\n\n\n```python\ndxp.bar(x='neighborhood', y='price', data=airbnb, \n        aggfunc='median', split='property_type',\n        split_order=['Apartment', 'House'], \n        x_order=['Dupont Circle', 'Capitol Hill', 'Union Station'], size=.5)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_56_0.png)\n\n\n\n### Splitting line plots\n\nAll the other aggregating plots work similarly.\n\n\n```python\ndxp.line(x='neighborhood', y='price', data=airbnb, \n        aggfunc='median', split='property_type',\n        split_order=['Apartment', 'House'], \n        x_order=['Dupont Circle', 'Capitol Hill', 'Union Station'])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_58_0.png)\n\n\n\n## Distribution plots - box, violin, histogram, kde\n\nDistribution plots work similarly, but do not have an `aggfunc` since they do not aggregate. They take their group of values and draw some kind of shape that gives information on how that variable is distributed. \n\n### Box plots\n\nBox plots have colored boxes with ends at the first and third quartiles and a line at the median. The whiskers are placed at 1.5 times the difference between the third and first quartiles (Interquartile range (IQR)). Fliers are the points outside this range and plotted individually. By default, both box and violin plots are plotted horizontally.\n\n\n```python\ndxp.box(x='price', y='neighborhood', data=airbnb)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_60_0.png)\n\n\n\nSplit the groups in the same manner as with the aggregation plots.\n\n\n```python\ndxp.box(x='price', y='neighborhood', data=airbnb, \n        split='superhost', split_order=['Yes', 'No'])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_62_0.png)\n\n\n\nOrder the appearance of the splits alphabetically (in descending order here).\n\n\n```python\ndxp.box(x='price', y='neighborhood', data=airbnb, \n        split='property_type', split_order='desc')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_64_0.png)\n\n\n\n### Filter range of values with `x_order`\n\nIt's possible to filter the range of possible values by passing in a list of the minimum and maximum to `x_order`.\n\n\n```python\ndxp.box(x='price', y='neighborhood', data=airbnb, \n        split='superhost', x_order=[50, 250])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_66_0.png)\n\n\n\nChange the `x` and `y` while setting `orientation` to make vertical bar plots.\n\n\n```python\ndxp.box(x='neighborhood', y='price', data=airbnb, orientation='v',\n        split='property_type', split_order='top 2')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_68_0.png)\n\n\n\nViolin plots work identically to box plots, but show \"violins\", kernel density plots duplicated on both sides of a line.\n\n\n```python\ndxp.violin(x='price', y='neighborhood', data=airbnb, \n          split='superhost', split_order=['Yes', 'No'])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_70_0.png)\n\n\n\nSplitting by rows and columns is possible as well with distribution plots.\n\n\n```python\ndxp.box(x='price', y='neighborhood', data=airbnb,split='superhost', \n        col='property_type', col_order=['House', 'Condominium', 'Apartment'],\n        row='bedrooms', row_order=[1, 2])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_72_0.png)\n\n\n\n### Histograms\n\nHistograms work in a slightly different manner. Instead of passing both `x` and `y`, you give it a single numeric column. A vertical histogram with 20 bins of the counts is created by default.\n\n\n```python\ndxp.hist(val='price', data=airbnb)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_74_0.png)\n\n\n\nWe can use `split` just like we did above and also create horizontal histograms.\n\n\n```python\ndxp.hist(val='price', data=airbnb, orientation='h', split='superhost', bins=15)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_76_0.png)\n\n\n\nHere, we customize our histogram by plotting the cumulative density as opposed to the raw frequency count using the outline of the bars ('step').\n\n\n```python\ndxp.hist(val='price', data=airbnb, split='bedrooms', split_order=[1, 2, 3], \n         bins=30, density=True, histtype='step', cumulative=True)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_78_0.png)\n\n\n\n### KDE Plots\n\nKernel density estimates provide an estimate for the probability distribution of a continuous variable. Here, we examine how price is distributed by bedroom.\n\n\n```python\ndxp.kde(x='price', data=airbnb, split='bedrooms', split_order=[1, 2, 3])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_80_0.png)\n\n\n\nGraph the cumulative distribution instead on multiple plots.\n\n\n```python\ndxp.kde(x='price', data=airbnb, split='bedrooms', \n        split_order=[1, 2, 3], cumulative=True, col='property_type', wrap=2)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_82_0.png)\n\n\n\n### Two-dimensional KDE's\n\nProvide two numeric columns to `x` and `y` to get a two dimensional KDE.\n\n\n```python\ndxp.kde(x='price', y='cleaning_fee', data=airbnb)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_84_0.png)\n\n\n\nCreate a grid of two-dimensional KDE's.\n\n\n```python\ndxp.kde(x='price', y='cleaning_fee', data=airbnb, row='neighborhood', wrap=3)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_86_0.png)\n\n\n\n## Count plots\n\nThe `count` function graphs the frequency of unique values as bars. By default, it plots the values in descending order.\n\n\n```python\ndxp.count(val='neighborhood', data=airbnb)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_88_0.png)\n\n\n\nIn pandas, this is a straightforward call to the `value_counts` method.\n\n\n```python\nairbnb['neighborhood'].value_counts()\n```\n\n\n\n\n    Columbia Heights    773\n    Union Station       713\n    Capitol Hill        654\n    Edgewood            610\n    Dupont Circle       549\n    Shaw                514\n    Brightwood Park     406\n    Kalorama Heights    362\n    Name: neighborhood, dtype: int64\n\n\n\n### Relative frequency with `normalize`\n\nInstead of the raw counts, get the relative frequency by setting normalize to `True`.\n\n\n```python\ndxp.count(val='neighborhood', data=airbnb, normalize=True)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_92_0.png)\n\n\n\nHere, we split by property type.\n\n\n```python\ndxp.count(val='neighborhood', data=airbnb, split='property_type')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_94_0.png)\n\n\n\nIn pandas, this is done with the `crosstab` function.\n\n\n```python\npd.crosstab(index=airbnb['property_type'], columns=airbnb['neighborhood'])\n```\n\n\n\n\n\u003cdiv\u003e\n\u003ctable border=\"1\" class=\"dataframe\"\u003e\n  \u003cthead\u003e\n    \u003ctr style=\"text-align: right;\"\u003e\n      \u003cth\u003eneighborhood\u003c/th\u003e\n      \u003cth\u003eBrightwood Park\u003c/th\u003e\n      \u003cth\u003eCapitol Hill\u003c/th\u003e\n      \u003cth\u003eColumbia Heights\u003c/th\u003e\n      \u003cth\u003eDupont Circle\u003c/th\u003e\n      \u003cth\u003eEdgewood\u003c/th\u003e\n      \u003cth\u003eKalorama Heights\u003c/th\u003e\n      \u003cth\u003eShaw\u003c/th\u003e\n      \u003cth\u003eUnion Station\u003c/th\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eproperty_type\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003cth\u003eApartment\u003c/th\u003e\n      \u003ctd\u003e167\u003c/td\u003e\n      \u003ctd\u003e299\u003c/td\u003e\n      \u003ctd\u003e374\u003c/td\u003e\n      \u003ctd\u003e397\u003c/td\u003e\n      \u003ctd\u003e244\u003c/td\u003e\n      \u003ctd\u003e284\u003c/td\u003e\n      \u003ctd\u003e315\u003c/td\u003e\n      \u003ctd\u003e323\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eCondominium\u003c/th\u003e\n      \u003ctd\u003e35\u003c/td\u003e\n      \u003ctd\u003e70\u003c/td\u003e\n      \u003ctd\u003e97\u003c/td\u003e\n      \u003ctd\u003e62\u003c/td\u003e\n      \u003ctd\u003e65\u003c/td\u003e\n      \u003ctd\u003e42\u003c/td\u003e\n      \u003ctd\u003e52\u003c/td\u003e\n      \u003ctd\u003e54\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eHouse\u003c/th\u003e\n      \u003ctd\u003e131\u003c/td\u003e\n      \u003ctd\u003e137\u003c/td\u003e\n      \u003ctd\u003e157\u003c/td\u003e\n      \u003ctd\u003e47\u003c/td\u003e\n      \u003ctd\u003e146\u003c/td\u003e\n      \u003ctd\u003e23\u003c/td\u003e\n      \u003ctd\u003e61\u003c/td\u003e\n      \u003ctd\u003e175\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eTownhouse\u003c/th\u003e\n      \u003ctd\u003e73\u003c/td\u003e\n      \u003ctd\u003e148\u003c/td\u003e\n      \u003ctd\u003e145\u003c/td\u003e\n      \u003ctd\u003e43\u003c/td\u003e\n      \u003ctd\u003e155\u003c/td\u003e\n      \u003ctd\u003e13\u003c/td\u003e\n      \u003ctd\u003e86\u003c/td\u003e\n      \u003ctd\u003e161\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\u003c/div\u003e\n\n\n\nHorizontal stacked count plots.\n\n\n```python\ndxp.count(val='neighborhood', data=airbnb, split='property_type', \n          orientation='h', stacked=True, col='superhost')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_98_0.png)\n\n\n\n### Normalize over different variables\n\nSetting `normalize` to `True`, returns the relative frequency with respect to all of the data. You can normalize over any of the variables provided.\n\n\n```python\ndxp.count(val='neighborhood', data=airbnb, split='property_type', normalize='neighborhood', \n                title='Relative Frequency by Neighborhood')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_100_0.png)\n\n\n\nNormalize over several variables at once with a list.\n\n\n```python\ndxp.count(val='neighborhood', data=airbnb, split='superhost', \n          row='property_type', col='bedrooms', col_order=[1, 2],\n          normalize=['neighborhood', 'property_type', 'bedrooms'], stacked=True)\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_102_0.png)\n\n\n\n## Wide data\n\nDexplot can also plot wide data, or data where no aggregation happens. Here is a scatter plot of the location of each listing.\n\n\n```python\ndxp.scatter(x='longitude', y='latitude', data=airbnb, \n            split='neighborhood', col='bedrooms', col_order=[2, 3])\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_104_0.png)\n\n\n\nIf you've already aggregated your data, you can plot it directly without specifying `x` or `y`.\n\n\n```python\ndf = airbnb.pivot_table(index='neighborhood', columns='property_type', \n                        values='price', aggfunc='mean')\ndf\n```\n\n\n\n\n\u003cdiv\u003e\n\n\u003ctable border=\"1\" class=\"dataframe\"\u003e\n  \u003cthead\u003e\n    \u003ctr style=\"text-align: right;\"\u003e\n      \u003cth\u003eproperty_type\u003c/th\u003e\n      \u003cth\u003eApartment\u003c/th\u003e\n      \u003cth\u003eCondominium\u003c/th\u003e\n      \u003cth\u003eHouse\u003c/th\u003e\n      \u003cth\u003eTownhouse\u003c/th\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eneighborhood\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003cth\u003eBrightwood Park\u003c/th\u003e\n      \u003ctd\u003e96.119760\u003c/td\u003e\n      \u003ctd\u003e105.000000\u003c/td\u003e\n      \u003ctd\u003e121.671756\u003c/td\u003e\n      \u003ctd\u003e133.479452\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eCapitol Hill\u003c/th\u003e\n      \u003ctd\u003e141.210702\u003c/td\u003e\n      \u003ctd\u003e104.200000\u003c/td\u003e\n      \u003ctd\u003e170.153285\u003c/td\u003e\n      \u003ctd\u003e184.459459\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eColumbia Heights\u003c/th\u003e\n      \u003ctd\u003e114.676471\u003c/td\u003e\n      \u003ctd\u003e126.773196\u003c/td\u003e\n      \u003ctd\u003e135.292994\u003c/td\u003e\n      \u003ctd\u003e124.358621\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eDupont Circle\u003c/th\u003e\n      \u003ctd\u003e146.858942\u003c/td\u003e\n      \u003ctd\u003e130.709677\u003c/td\u003e\n      \u003ctd\u003e179.574468\u003c/td\u003e\n      \u003ctd\u003e139.348837\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eEdgewood\u003c/th\u003e\n      \u003ctd\u003e108.508197\u003c/td\u003e\n      \u003ctd\u003e112.846154\u003c/td\u003e\n      \u003ctd\u003e156.335616\u003c/td\u003e\n      \u003ctd\u003e147.503226\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eKalorama Heights\u003c/th\u003e\n      \u003ctd\u003e122.542254\u003c/td\u003e\n      \u003ctd\u003e155.928571\u003c/td\u003e\n      \u003ctd\u003e92.695652\u003c/td\u003e\n      \u003ctd\u003e158.230769\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eShaw\u003c/th\u003e\n      \u003ctd\u003e153.888889\u003c/td\u003e\n      \u003ctd\u003e158.500000\u003c/td\u003e\n      \u003ctd\u003e202.114754\u003c/td\u003e\n      \u003ctd\u003e173.279070\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003eUnion Station\u003c/th\u003e\n      \u003ctd\u003e128.458204\u003c/td\u003e\n      \u003ctd\u003e133.833333\u003c/td\u003e\n      \u003ctd\u003e162.748571\u003c/td\u003e\n      \u003ctd\u003e162.167702\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\u003c/div\u003e\n\n\n\n\n```python\ndxp.bar(data=df, orientation='h')\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_107_0.png)\n\n\n\n### Time series\n\n\n```python\nstocks = pd.read_csv('../data/stocks10.csv', parse_dates=['date'], index_col='date')\nstocks.head()\n```\n\n\n\n\n\u003cdiv\u003e\n\u003ctable border=\"1\" class=\"dataframe\"\u003e\n  \u003cthead\u003e\n    \u003ctr style=\"text-align: right;\"\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003eMSFT\u003c/th\u003e\n      \u003cth\u003eAAPL\u003c/th\u003e\n      \u003cth\u003eSLB\u003c/th\u003e\n      \u003cth\u003eAMZN\u003c/th\u003e\n      \u003cth\u003eTSLA\u003c/th\u003e\n      \u003cth\u003eXOM\u003c/th\u003e\n      \u003cth\u003eWMT\u003c/th\u003e\n      \u003cth\u003eT\u003c/th\u003e\n      \u003cth\u003eFB\u003c/th\u003e\n      \u003cth\u003eV\u003c/th\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003edate\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n      \u003cth\u003e\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003cth\u003e1999-10-25\u003c/th\u003e\n      \u003ctd\u003e29.84\u003c/td\u003e\n      \u003ctd\u003e2.32\u003c/td\u003e\n      \u003ctd\u003e17.02\u003c/td\u003e\n      \u003ctd\u003e82.75\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e21.45\u003c/td\u003e\n      \u003ctd\u003e38.99\u003c/td\u003e\n      \u003ctd\u003e16.78\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e1999-10-26\u003c/th\u003e\n      \u003ctd\u003e29.82\u003c/td\u003e\n      \u003ctd\u003e2.34\u003c/td\u003e\n      \u003ctd\u003e16.65\u003c/td\u003e\n      \u003ctd\u003e81.25\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e20.89\u003c/td\u003e\n      \u003ctd\u003e37.11\u003c/td\u003e\n      \u003ctd\u003e17.28\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e1999-10-27\u003c/th\u003e\n      \u003ctd\u003e29.33\u003c/td\u003e\n      \u003ctd\u003e2.38\u003c/td\u003e\n      \u003ctd\u003e16.52\u003c/td\u003e\n      \u003ctd\u003e75.94\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e20.80\u003c/td\u003e\n      \u003ctd\u003e36.94\u003c/td\u003e\n      \u003ctd\u003e18.27\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e1999-10-28\u003c/th\u003e\n      \u003ctd\u003e29.01\u003c/td\u003e\n      \u003ctd\u003e2.43\u003c/td\u003e\n      \u003ctd\u003e16.59\u003c/td\u003e\n      \u003ctd\u003e71.00\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e21.19\u003c/td\u003e\n      \u003ctd\u003e38.85\u003c/td\u003e\n      \u003ctd\u003e19.79\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n      \u003cth\u003e1999-10-29\u003c/th\u003e\n      \u003ctd\u003e29.88\u003c/td\u003e\n      \u003ctd\u003e2.50\u003c/td\u003e\n      \u003ctd\u003e17.21\u003c/td\u003e\n      \u003ctd\u003e70.62\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003e21.47\u003c/td\u003e\n      \u003ctd\u003e39.25\u003c/td\u003e\n      \u003ctd\u003e20.00\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n      \u003ctd\u003eNaN\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n\u003c/table\u003e\n\u003c/div\u003e\n\n\n\n\n```python\ndxp.line(data=stocks.head(500))\n```\n\n\n\n\n![png](https://raw.githubusercontent.com/dexplo/dexplot/gh-pages/images/output_110_0.png)\n\n\n","funding_links":["https://dunderdata.com"],"categories":["Jupyter Notebook"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdexplo%2Fdexplot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdexplo%2Fdexplot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdexplo%2Fdexplot/lists"}