@@ -1082,6 +1082,13 @@ type Chart =
1082
1082
?Scalegroup= Scalegroup,? Scalemode= Scalemode,? Side= Side,? Span= Span,? SpanMode= SpanMode,? Uirevision= Uirevision
1083
1083
)
1084
1084
1085
+ static member private renderHeatmapTrace ( useWebGL : bool ) ( style : Trace -> Trace ) =
1086
+ if useWebGL then
1087
+ Trace.initHeatmapGL style
1088
+ |> GenericChart.ofTraceObject
1089
+ else
1090
+ Trace.initHeatmap style
1091
+ |> GenericChart.ofTraceObject
1085
1092
1086
1093
/// Shows a graphical representation of a 3-dimensional surface by plotting constant z slices, called contours, on a 2-dimensional format.
1087
1094
/// That is, given a value for z, lines are drawn for connecting the (x,y) coordinates where that z value occurs.
@@ -1096,11 +1103,17 @@ type Chart =
1096
1103
[<Optional; DefaultParameterValue( null ) >] ? Xgap ,
1097
1104
[<Optional; DefaultParameterValue( null ) >] ? Ygap ,
1098
1105
[<Optional; DefaultParameterValue( null ) >] ? zSmooth ,
1099
- [<Optional; DefaultParameterValue( null ) >] ? Colorbar ) =
1100
- Trace.initHeatmap ( TraceStyle.Heatmap( Z= data,? X= ColNames, ?Y= RowNames,
1101
- ?Xgap= Xgap,? Ygap= Ygap,? Colorscale= Colorscale,? Showscale= Showscale,? zSmooth= zSmooth,? Colorbar= Colorbar) )
1102
- |> TraceStyle.TraceInfo( ?Name= Name,? Showlegend= Showlegend,? Opacity= Opacity)
1103
- |> GenericChart.ofTraceObject
1106
+ [<Optional; DefaultParameterValue( null ) >] ? Colorbar ,
1107
+ [<Optional; DefaultParameterValue( false ) >] ? UseWebGL : bool )
1108
+ =
1109
+ let style =
1110
+ TraceStyle.Heatmap( Z= data,? X= ColNames, ?Y= RowNames,
1111
+ ?Xgap= Xgap,? Ygap= Ygap,? Colorscale= Colorscale,? Showscale= Showscale,? zSmooth= zSmooth,? Colorbar= Colorbar)
1112
+ >> TraceStyle.TraceInfo( ?Name= Name,? Showlegend= Showlegend,? Opacity= Opacity)
1113
+
1114
+ let useWebGL = defaultArg UseWebGL false
1115
+
1116
+ Chart.renderHeatmapTrace useWebGL style
1104
1117
1105
1118
1106
1119
/// Shows a graphical representation of data where the individual values contained in a matrix are represented as colors.
0 commit comments