Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 788dcf9

Browse files
committed
string doc and CHANGELOG update
1 parent 5e0acc2 commit 788dcf9

File tree

2 files changed

+24
-7
lines changed

2 files changed

+24
-7
lines changed

CHANGELOG.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,12 @@
22
All notable changes to this project will be documented in this file.
33
This project adheres to [Semantic Versioning](http://semver.org/).
44

5-
## [Unreleased]
6-
### Added
7-
- `figure_factory.create_facet_grid` now supports histogram traces.
8-
95
## [2.0.12] - UNRELEASED
106
### Updated
117
- Updated `plotly.min.js` to version 1.28.2 for `plotly.offline`.
128
- See [the plotly.js CHANGELOG](https://github.com/plotly/plotly.js/blob/master/CHANGELOG.md#1282----2017-06-21) for additional information regarding the updates.
9+
### Added
10+
- `figure_factory.create_facet_grid` now supports histogram, bar, and box traces.
1311

1412
## [2.0.11] - 2017-06-20
1513
### Updated

plotly/figure_factory/_facet_grid.py

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -637,7 +637,8 @@ def create_facet_grid(df, x=None, y=None, facet_row=None, facet_col=None,
637637
:param (int) height: the height of the facet grid figure.
638638
:param (int) width: the width of the facet grid figure.
639639
:param (str) trace_type: decides the type of plot to appear in the
640-
facet grid. The options are 'scatter', 'scattergl' and 'histogram'.
640+
facet grid. The options are 'scatter', 'scattergl', 'histogram',
641+
'bar', and 'box'.
641642
Default = 'scatter'.
642643
:param (str) scales: determines if axes have fixed ranges or not. Valid
643644
settings are 'fixed' (all axes fixed), 'free_x' (x axis free only),
@@ -668,7 +669,6 @@ def create_facet_grid(df, x=None, y=None, facet_row=None, facet_col=None,
668669
y='cty',
669670
facet_col='cyl',
670671
)
671-
672672
py.iplot(fig, filename='facet_grid_mpg_one_way_facet')
673673
```
674674
@@ -688,7 +688,6 @@ def create_facet_grid(df, x=None, y=None, facet_row=None, facet_col=None,
688688
facet_row='drv',
689689
facet_col='cyl',
690690
)
691-
692691
py.iplot(fig, filename='facet_grid_mpg_two_way_facet')
693692
```
694693
@@ -752,6 +751,26 @@ def create_facet_grid(df, x=None, y=None, facet_row=None, facet_col=None,
752751
753752
py.iplot(fig, filename='facet_grid_mtcars_custom_labels')
754753
```
754+
755+
Example 6: Other Trace Type
756+
```
757+
import plotly.plotly as py
758+
import plotly.figure_factory as ff
759+
760+
import pandas as pd
761+
762+
mtcars = pd.read_csv('https://raw.githubusercontent.com/plotly/datasets/master/mtcars.csv')
763+
764+
fig = ff.create_facet_grid(
765+
mtcars,
766+
x='wt',
767+
y='mpg',
768+
facet_col='cyl',
769+
trace_type='histogram',
770+
)
771+
772+
py.iplot(fig, filename='facet_grid_mtcars_other_trace_type')
773+
```
755774
"""
756775
if not pd:
757776
raise exceptions.ImportError(

0 commit comments

Comments
 (0)