@@ -1751,7 +1751,7 @@ type Chart =
1751
1751
let currentAxis =
1752
1752
polar |> Polar.getAngularAxis
1753
1753
1754
- let updatedAxis = DynObj.combine currentAxis angularAxis
1754
+ let updatedAxis = DynObj.combine currentAxis angularAxis |> unbox < AngularAxis >
1755
1755
1756
1756
let updatedPolar =
1757
1757
polar |> Polar.setAngularAxis updatedAxis
@@ -1810,7 +1810,7 @@ type Chart =
1810
1810
polar |> Polar.getRadialAxis
1811
1811
1812
1812
let updatedAxis =
1813
- DynObj.combine currentAxis radialAxis
1813
+ DynObj.combine currentAxis radialAxis |> unbox < RadialAxis >
1814
1814
1815
1815
let updatedPolar =
1816
1816
polar |> Polar.setRadialAxis updatedAxis
@@ -1925,10 +1925,10 @@ type Chart =
1925
1925
let currentAxis =
1926
1926
smith |> Smith.getImaginaryAxis
1927
1927
1928
- let updatedAxis = DynObj.combine currentAxis imaginaryAxis
1928
+ let updatedAxis = DynObj.combine currentAxis imaginaryAxis |> unbox < ImaginaryAxis >
1929
1929
1930
1930
let updatedSmith =
1931
- smith |> Smith.setImaginaryAxis updatedAxis
1931
+ smith |> Smith.setImaginaryAxis updatedAxis
1932
1932
1933
1933
layout |> Layout.updateSmithById ( id, updatedSmith)
1934
1934
@@ -1982,10 +1982,10 @@ type Chart =
1982
1982
if combine then
1983
1983
let currentAxis = smith |> Smith.getRealAxis
1984
1984
1985
- let updatedAxis = DynObj.combine currentAxis realAxis
1985
+ let updatedAxis = DynObj.combine currentAxis realAxis |> unbox < RealAxis >
1986
1986
1987
1987
let updatedSmith =
1988
- smith |> Smith.setRealAxis updatedAxis
1988
+ smith |> Smith.setRealAxis updatedAxis
1989
1989
1990
1990
layout |> Layout.updateSmithById ( id, updatedSmith)
1991
1991
@@ -2364,10 +2364,10 @@ type Chart =
2364
2364
let currentAxis =
2365
2365
ternary |> Ternary.getAAxis
2366
2366
2367
- let updatedAxis = DynObj.combine currentAxis aAxis
2367
+ let updatedAxis = DynObj.combine currentAxis aAxis |> unbox < LinearAxis >
2368
2368
2369
2369
let updatedTernary =
2370
- ternary |> Ternary.setAAxis updatedAxis
2370
+ ternary |> Ternary.setAAxis updatedAxis
2371
2371
2372
2372
layout |> Layout.updateTernaryById ( id, updatedTernary)
2373
2373
@@ -2423,7 +2423,7 @@ type Chart =
2423
2423
let currentAxis =
2424
2424
ternary |> Ternary.getBAxis
2425
2425
2426
- let updatedAxis = DynObj.combine currentAxis bAxis
2426
+ let updatedAxis = DynObj.combine currentAxis bAxis |> unbox < LinearAxis >
2427
2427
2428
2428
let updatedTernary =
2429
2429
ternary |> Ternary.setBAxis updatedAxis
@@ -2482,7 +2482,7 @@ type Chart =
2482
2482
let currentAxis =
2483
2483
ternary |> Ternary.getCAxis
2484
2484
2485
- let updatedAxis = DynObj.combine currentAxis cAxis
2485
+ let updatedAxis = DynObj.combine currentAxis cAxis |> unbox < LinearAxis >
2486
2486
2487
2487
let updatedTernary =
2488
2488
ternary |> Ternary.setCAxis updatedAxis
@@ -3176,8 +3176,9 @@ type Chart =
3176
3176
calculateSubplotTitlePositions 0. 1. xGap yGap nRows nCols reversed
3177
3177
3178
3178
titles
3179
- |> Seq.zip positions[ 0 .. ( Seq.length titles) - 1 ]
3180
- |> Seq.map ( fun ((( rowIndex , colIndex ), ( x , y )), title ) ->
3179
+ |> Array.ofSeq
3180
+ |> Array.zip positions[ 0 .. ( Seq.length titles) - 1 ]
3181
+ |> Array.map ( fun ((( rowIndex , colIndex ), ( x , y )), title ) ->
3181
3182
Annotation.init(
3182
3183
X = x,
3183
3184
XRef = " paper" ,
@@ -3199,7 +3200,8 @@ type Chart =
3199
3200
3200
3201
gCharts
3201
3202
|> Seq.zip gridCoordinates
3202
- |> Seq.mapi ( fun i (( rowIndex , colIndex ), gChart ) ->
3203
+ |> Array.ofSeq
3204
+ |> Array.mapi ( fun i (( rowIndex , colIndex ), gChart ) ->
3203
3205
3204
3206
let layout =
3205
3207
gChart |> GenericChart.getLayout
@@ -3217,35 +3219,36 @@ type Chart =
3217
3219
let yAxis =
3218
3220
layout.TryGetTypedPropertyValue< LinearAxis> " yaxis" |> Option.defaultValue ( LinearAxis.init ())
3219
3221
3220
- let allXAxes = Layout.getXAxes layout |> Seq .map fst
3221
- let allYAxes = Layout.getYAxes layout |> Seq .map fst
3222
+ let allXAxes = Layout.getXAxes layout |> Array .map fst
3223
+ let allYAxes = Layout.getYAxes layout |> Array .map fst
3222
3224
3223
3225
// remove all axes from layout. Only cartesian axis in each dimension is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3224
- allXAxes |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3225
- allYAxes |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3226
+ allXAxes |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3227
+ allYAxes |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3226
3228
3227
3229
let xAnchor , yAnchor =
3228
3230
if hasSharedAxes then
3229
3231
colIndex, rowIndex //set axis anchors according to grid coordinates
3230
3232
else
3231
3233
i + 1 , i + 1
3232
3234
3233
- gChart
3234
- |> Chart.withAxisAnchor ( xAnchor, yAnchor) // set adapted axis anchors
3235
- |> Chart.withXAxis ( xAxis, ( StyleParam.SubPlotId.XAxis( i + 1 ))) // set previous axis with adapted id (one individual axis for each subplot, whether or not they will be used later)
3236
- |> Chart.withYAxis ( yAxis, ( StyleParam.SubPlotId.YAxis( i + 1 ))) // set previous axis with adapted id (one individual axis for each subplot, whether or not they will be used later)
3237
-
3235
+ let lol =
3236
+ gChart
3237
+ |> Chart.withAxisAnchor ( xAnchor, yAnchor) // set adapted axis anchors
3238
+ |> Chart.withXAxis ( xAxis, ( StyleParam.SubPlotId.XAxis( i + 1 ))) // set previous axis with adapted id (one individual axis for each subplot, whether or not they will be used later)
3239
+ |> Chart.withYAxis ( yAxis, ( StyleParam.SubPlotId.YAxis( i + 1 ))) // set previous axis with adapted id (one individual axis for each subplot, whether or not they will be used later)
3240
+ lol
3238
3241
| TraceID.Cartesian3D ->
3239
3242
3240
3243
let scene =
3241
3244
layout.TryGetTypedPropertyValue< Scene> " scene"
3242
3245
|> Option.defaultValue ( Scene.init ())
3243
3246
|> Scene.style ( Domain = LayoutObjects.Domain.init ( Row = rowIndex - 1 , Column = colIndex - 1 ))
3244
3247
3245
- let allScenes = Layout.getScenes layout |> Seq .map fst
3248
+ let allScenes = Layout.getScenes layout |> Array .map fst
3246
3249
3247
3250
// remove all scenes from layout. Only one scene is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3248
- allScenes |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3251
+ allScenes |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3249
3252
3250
3253
let sceneAnchor =
3251
3254
StyleParam.SubPlotId.Scene( i + 1 )
@@ -3260,10 +3263,10 @@ type Chart =
3260
3263
|> Option.defaultValue ( Polar.init ())
3261
3264
|> Polar.style ( Domain = LayoutObjects.Domain.init ( Row = rowIndex - 1 , Column = colIndex - 1 ))
3262
3265
3263
- let allPolars = Layout.getPolars layout |> Seq .map fst
3266
+ let allPolars = Layout.getPolars layout |> Array .map fst
3264
3267
3265
3268
// remove all polar subplots from layout. Only one polar subplot is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3266
- allPolars |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3269
+ allPolars |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3267
3270
3268
3271
let polarAnchor =
3269
3272
StyleParam.SubPlotId.Polar( i + 1 )
@@ -3280,10 +3283,10 @@ type Chart =
3280
3283
|> Option.defaultValue ( Smith.init ())
3281
3284
|> Smith.style ( Domain = LayoutObjects.Domain.init ( Row = rowIndex - 1 , Column = colIndex - 1 ))
3282
3285
3283
- let allSmiths = Layout.getSmiths layout |> Seq .map fst
3286
+ let allSmiths = Layout.getSmiths layout |> Array .map fst
3284
3287
3285
3288
// remove all smith subplots from layout. Only one smith subplot is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3286
- allSmiths |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3289
+ allSmiths |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3287
3290
3288
3291
let polarAnchor =
3289
3292
StyleParam.SubPlotId.Smith( i + 1 )
@@ -3299,10 +3302,10 @@ type Chart =
3299
3302
|> Option.defaultValue ( Geo.init ())
3300
3303
|> Geo.style ( Domain = LayoutObjects.Domain.init ( Row = rowIndex - 1 , Column = colIndex - 1 ))
3301
3304
3302
- let allGeos = Layout.getGeos layout |> Seq .map fst
3305
+ let allGeos = Layout.getGeos layout |> Array .map fst
3303
3306
3304
3307
// remove all geo subplots from layout. Only one geo subplot is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3305
- allGeos |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3308
+ allGeos |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3306
3309
3307
3310
let geoAnchor =
3308
3311
StyleParam.SubPlotId.Geo( i + 1 )
@@ -3319,10 +3322,10 @@ type Chart =
3319
3322
Domain = LayoutObjects.Domain.init ( Row = rowIndex - 1 , Column = colIndex - 1 )
3320
3323
)
3321
3324
3322
- let allMapboxes = Layout.getMapboxes layout |> Seq .map fst
3325
+ let allMapboxes = Layout.getMapboxes layout |> Array .map fst
3323
3326
3324
3327
// remove all mapbox subplots from layout. Only one mapbox subplot is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3325
- allMapboxes |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3328
+ allMapboxes |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3326
3329
3327
3330
let geoAnchor =
3328
3331
StyleParam.SubPlotId.Geo( i + 1 )
@@ -3344,10 +3347,10 @@ type Chart =
3344
3347
Domain = LayoutObjects.Domain.init ( Row = rowIndex - 1 , Column = colIndex - 1 )
3345
3348
)
3346
3349
3347
- let allTernaries = Layout.getTernaries layout |> Seq .map fst
3350
+ let allTernaries = Layout.getTernaries layout |> Array .map fst
3348
3351
3349
3352
// remove all ternary subplots from layout. Only one ternary subplot is supported per grid cell, and leaving anything else on this layout may lead to property name clashes on combine.
3350
- allTernaries |> Seq .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3353
+ allTernaries |> Array .iter ( fun propName -> layout.RemoveProperty( propName) |> ignore)
3351
3354
3352
3355
let ternaryAnchor =
3353
3356
StyleParam.SubPlotId.Ternary( i + 1 )
0 commit comments