Skip to content

Commit 10f83ff

Browse files
committed
fix #154
1 parent a2e59a4 commit 10f83ff

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

src/Plotly.NET/CommonAbstractions/StyleParams.fs

+1-1
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ module StyleParam =
251251
static member toString = function
252252
| True -> "true"
253253
| False -> "false"
254-
| SD -> "SD"
254+
| SD -> "sd"
255255

256256
static member convert = BoxMean.toString >> box
257257
override this.ToString() = this |> BoxMean.toString

src/Plotly.NET/Playground.fsx

+11-4
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,14 @@ open FSharpAux
161161
open System
162162
open System.IO
163163

164+
let y=[2.37; 2.16; 4.82; 1.73; 1.04; 0.23; 1.32; 2.91; 0.11; 4.51; 0.51; 3.75; 1.35; 2.98; 4.50; 0.18; 4.66; 1.30; 2.06; 1.19]
164165

166+
[
167+
Chart.BoxPlot(y=y,BoxPoints=StyleParam.BoxPoints.All,Jitter=0.5,Notched=true,MarkerColor = Color.fromString "red",BoxMean=StyleParam.BoxMean.True,Name="Only Mean");
168+
Chart.BoxPlot(y=y,BoxPoints=StyleParam.BoxPoints.All,Jitter=0.5,Notched=true,MarkerColor = Color.fromString "blue",BoxMean=StyleParam.BoxMean.SD,Name="Mean & SD")
169+
]
170+
|> Chart.combine
171+
|> Chart.show
165172

166173
[
167174
Chart.Histogram(
@@ -664,8 +671,8 @@ Chart.Invisible()
664671

665672

666673
[
667-
Chart.BoxPlot("y" ,y,Name="bin1",Jitter=0.1,Boxpoints=StyleParam.Boxpoints.All);
668-
Chart.BoxPlot("y'",y',Name="bin2",Jitter=0.1,Boxpoints=StyleParam.Boxpoints.All);
674+
Chart.BoxPlot("y" ,y,Name="bin1",Jitter=0.1,BoxPoints=StyleParam.BoxPoints.All);
675+
Chart.BoxPlot("y'",y',Name="bin2",Jitter=0.1,BoxPoints=StyleParam.BoxPoints.All);
669676
]
670677
|> Chart.combine
671678

@@ -705,8 +712,8 @@ let heatmap2=
705712
Chart.PointMapbox([1,2]) |> Chart.withMapbox(Mapbox.init(Style = StyleParam.MapboxStyle.OpenStreetMap))
706713
[
707714
let y = [2.; 1.5; 5.; 1.5; 2.; 2.5; 2.1; 2.5; 1.5; 1.;2.; 1.5; 5.; 1.5; 3.; 2.5; 2.5; 1.5; 3.5; 1.]
708-
Chart.BoxPlot("y" ,y,Name="bin1",Jitter=0.1,Boxpoints=StyleParam.Boxpoints.All);
709-
Chart.BoxPlot("y'",y,Name="bin2",Jitter=0.1,Boxpoints=StyleParam.Boxpoints.All);
715+
Chart.BoxPlot("y" ,y,Name="bin1",Jitter=0.1,BoxPoints=StyleParam.BoxPoints.All);
716+
Chart.BoxPlot("y'",y,Name="bin2",Jitter=0.1,BoxPoints=StyleParam.BoxPoints.All);
710717
]
711718
|> Chart.combine
712719
]

0 commit comments

Comments
 (0)