@@ -488,6 +488,7 @@ def _facet_grid(df, x, y, facet_row, facet_col, num_of_rows,
488
488
),
489
489
** kwargs_trace
490
490
)
491
+
491
492
if trace_type in ['scatter' , 'scattergl' ]:
492
493
trace ['mode' ] = 'markers'
493
494
trace ['marker' ] = dict (color = marker_color , ** kwargs_marker )
@@ -770,10 +771,10 @@ def create_facet_grid(df, x, y, facet_row=None, facet_col=None,
770
771
"'scales' must be set to 'fixed', 'free_x', 'free_y' and 'free'."
771
772
)
772
773
773
- if trace_type not in VALID_TRACE_TYPES :
774
- raise exceptions .PlotlyError (
775
- "'trace_type' must be in {}" .format (VALID_TRACE_TYPES )
776
- )
774
+ # if trace_type not in VALID_TRACE_TYPES:
775
+ # raise exceptions.PlotlyError(
776
+ # "'trace_type' must be in {}".format(VALID_TRACE_TYPES)
777
+ # )
777
778
778
779
# seperate kwargs for marker and else
779
780
if 'marker' in kwargs :
@@ -988,15 +989,15 @@ def create_facet_grid(df, x, y, facet_row=None, facet_col=None,
988
989
fixed_axes = ['y' ]
989
990
elif scales == 'free_y' :
990
991
fixed_axes = ['x' ]
991
- else :
992
+ elif scales == 'free' :
992
993
fixed_axes = []
993
994
994
995
# fixed ranges
995
- for x_y in [ 'x' , 'y' ] :
996
+ for x_y in fixed_axes :
996
997
min_ranges = []
997
998
max_ranges = []
998
999
for trace in fig ['data' ]:
999
- if len (trace [x_y ]) > 0 :
1000
+ if trace [ x_y ] is not None and len (trace [x_y ]) > 0 :
1000
1001
min_ranges .append (min (trace [x_y ]))
1001
1002
max_ranges .append (max (trace [x_y ]))
1002
1003
while None in min_ranges :
0 commit comments