diff --git a/Plotly.NET.sln b/Plotly.NET.sln
index e65c1d305..4c91c96fc 100644
--- a/Plotly.NET.sln
+++ b/Plotly.NET.sln
@@ -119,6 +119,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{EAE25A1F
src\Plotly.NET\Playground.fsx = src\Plotly.NET\Playground.fsx
EndProjectSection
EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Plotly.NET.Tests.CSharp", "tests\Plotly.NET.Tests.CSharp\Plotly.NET.Tests.CSharp.csproj", "{C3CEE309-4C3F-4927-B012-220DB37750F6}"
+EndProject
+Project("{6EC3EE1D-3C4E-46DD-8F32-0CC8E7565705}") = "Plotly.NET.Tests.FSharpConsole", "tests\Plotly.NET.Tests.FSharpConsole\Plotly.NET.Tests.FSharpConsole.fsproj", "{60114ACE-77E6-4A19-9A2F-CB64084174AF}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -150,6 +154,18 @@ Global
{6CFC629E-1A0C-4EF3-8495-BA00A356A381}.Dotnet|Any CPU.Build.0 = Debug|Any CPU
{6CFC629E-1A0C-4EF3-8495-BA00A356A381}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6CFC629E-1A0C-4EF3-8495-BA00A356A381}.Release|Any CPU.Build.0 = Release|Any CPU
+ {C3CEE309-4C3F-4927-B012-220DB37750F6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {C3CEE309-4C3F-4927-B012-220DB37750F6}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {C3CEE309-4C3F-4927-B012-220DB37750F6}.Dotnet|Any CPU.ActiveCfg = Debug|Any CPU
+ {C3CEE309-4C3F-4927-B012-220DB37750F6}.Dotnet|Any CPU.Build.0 = Debug|Any CPU
+ {C3CEE309-4C3F-4927-B012-220DB37750F6}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {C3CEE309-4C3F-4927-B012-220DB37750F6}.Release|Any CPU.Build.0 = Release|Any CPU
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF}.Dotnet|Any CPU.ActiveCfg = Debug|Any CPU
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF}.Dotnet|Any CPU.Build.0 = Debug|Any CPU
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@@ -162,6 +178,8 @@ Global
{60FB82C0-F472-494E-BCF7-7B3C54212406} = {7B09CC0A-F1E1-4094-9DE4-B047581E01F0}
{CDB973F2-0F60-4ADB-84A8-924AFA8B6D49} = {7B09CC0A-F1E1-4094-9DE4-B047581E01F0}
{6CFC629E-1A0C-4EF3-8495-BA00A356A381} = {0E87E47E-9EDC-4525-AF72-F0E139D54236}
+ {C3CEE309-4C3F-4927-B012-220DB37750F6} = {EAE25A1F-86FC-426B-803F-1006D1AD06A8}
+ {60114ACE-77E6-4A19-9A2F-CB64084174AF} = {EAE25A1F-86FC-426B-803F-1006D1AD06A8}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {7177F1E1-341C-48AB-9864-6B525FFF7633}
diff --git a/docs/1_0_axis-styling.fsx b/docs/1_0_axis-styling.fsx
index 7e317c37f..adfda4208 100644
--- a/docs/1_0_axis-styling.fsx
+++ b/docs/1_0_axis-styling.fsx
@@ -63,8 +63,10 @@ for even more fine-grained control, initialize a new axis and replace the old on
The following example creates two mirrored axes with inside ticks, one of them with a log scale:
*)
+open Plotly.NET.LayoutObjects // this namespace contains all object abstractions for layout styling
+
let mirroredXAxis =
- Axis.LinearAxis.init(
+ LinearAxis.init(
Title = Title.init(Text="Mirrored axis"),
ShowLine = true,
Mirror = StyleParam.Mirror.AllTicks,
@@ -73,7 +75,7 @@ let mirroredXAxis =
)
let mirroredLogYAxis =
- Axis.LinearAxis.init(
+ LinearAxis.init(
Title = Title.init(Text="Log axis"),
AxisType = StyleParam.AxisType.Log,
ShowLine = true,
diff --git a/docs/1_3_shapes.fsx b/docs/1_3_shapes.fsx
index 93098134e..735038745 100644
--- a/docs/1_3_shapes.fsx
+++ b/docs/1_3_shapes.fsx
@@ -45,6 +45,8 @@ multiple shapes at once.
**Attention**: Adding a shape after you added a previous one currently removes the old one. This is a bug and will be fixed
*)
+open Plotly.NET.LayoutObjects
+
let s1 = Shape.init (StyleParam.ShapeType.Rectangle,2.,4.,3.,4.,Opacity=0.3,Fillcolor="#d3d3d3")
let s2 = Shape.init (StyleParam.ShapeType.Rectangle,5.,7.,3.,4.,Opacity=0.3,Fillcolor="#d3d3d3")
diff --git a/docs/1_4_annotations.fsx b/docs/1_4_annotations.fsx
index fb16f4991..e1b580b3c 100644
--- a/docs/1_4_annotations.fsx
+++ b/docs/1_4_annotations.fsx
@@ -46,6 +46,8 @@ multiple annotations at once.
**Attention**: Adding an annotation after you added a previous one currently removes the old one. This is a bug and will be fixed
*)
+open Plotly.NET.LayoutObjects
+
let a1 = Annotation.init (X=2.,Y=4.,Text = "Hi there!")
let a2 = Annotation.init (X=5.,Y=7.,Text="I am another annotation!",BGColor="white",BorderColor="black")
diff --git a/docs/3_1_3d-surface-plots.fsx b/docs/3_1_3d-surface-plots.fsx
index 3caac124e..f7a324116 100644
--- a/docs/3_1_3d-surface-plots.fsx
+++ b/docs/3_1_3d-surface-plots.fsx
@@ -73,6 +73,8 @@ let z' = [
[1.;2.;];
] // column (length y)
+open Plotly.NET.TraceObjects
+
let surface2 =
Chart.Surface(z',x',y',Opacity=0.5,Contours=Contours.initXyz(Show=true))
diff --git a/docs/3_2_3d-mesh-plots.fsx b/docs/3_2_3d-mesh-plots.fsx
index d45684b84..fe2db8f95 100644
--- a/docs/3_2_3d-mesh-plots.fsx
+++ b/docs/3_2_3d-mesh-plots.fsx
@@ -62,9 +62,10 @@ let a = Array.init 50 (fun _ -> rnd.NextDouble())
let b = Array.init 50 (fun _ -> rnd.NextDouble())
let c = Array.init 50 (fun _ -> rnd.NextDouble())
+open Plotly.NET.TraceObjects
let mesh3d =
- Trace3d.initMesh3d
+ Trace3D.initMesh3d
(fun mesh3d ->
mesh3d?x <- a
mesh3d?y <- b
diff --git a/docs/3_4_3d-streamtube-plots.fsx b/docs/3_4_3d-streamtube-plots.fsx
index ac01ef418..24ab555da 100644
--- a/docs/3_4_3d-streamtube-plots.fsx
+++ b/docs/3_4_3d-streamtube-plots.fsx
@@ -38,6 +38,7 @@ open Deedle
open FSharp.Data
open System
open Plotly.NET
+open Plotly.NET.TraceObjects
let tubeData =
Http.RequestString @"https://raw.githubusercontent.com/plotly/datasets/master/streamtube-wind.csv"
diff --git a/docs/3_5_3d-volume-plots.fsx b/docs/3_5_3d-volume-plots.fsx
index 1a1df3ba8..7f47e5462 100644
--- a/docs/3_5_3d-volume-plots.fsx
+++ b/docs/3_5_3d-volume-plots.fsx
@@ -62,6 +62,8 @@ let values =
sin(x*y*z) / (x*y*z)
) x y z
+open Plotly.NET.TraceObjects
+
let volume =
Chart.Volume(
x, y, z, values,
diff --git a/docs/3_6_3d-isosurface-plots .fsx b/docs/3_6_3d-isosurface-plots .fsx
index bc5d98e01..75014a7a1 100644
--- a/docs/3_6_3d-isosurface-plots .fsx
+++ b/docs/3_6_3d-isosurface-plots .fsx
@@ -62,6 +62,8 @@ let valueIso =
x * x * 0.5 + y * y + z * z * 2.
) xIso yIso zIso
+open Plotly.NET.TraceObjects
+
let isoSurface =
Chart.IsoSurface(
xIso,yIso,zIso,valueIso,
diff --git a/docs/4_2_violin-plots.fsx b/docs/4_2_violin-plots.fsx
index 63dc52b29..72499f7e9 100644
--- a/docs/4_2_violin-plots.fsx
+++ b/docs/4_2_violin-plots.fsx
@@ -62,6 +62,8 @@ violin1 |> GenericChart.toChartHTML
(**
By swapping x and y plus using `StyleParam.Orientation.Horizontal` we can flip the chart horizontaly.
*)
+open Plotly.NET.TraceObjects
+
let violin2 =
Chart.Violin(
y,x,
diff --git a/docs/5_0_geo-vs-mapbox.fsx b/docs/5_0_geo-vs-mapbox.fsx
index c5a9c6938..371110514 100644
--- a/docs/5_0_geo-vs-mapbox.fsx
+++ b/docs/5_0_geo-vs-mapbox.fsx
@@ -66,6 +66,7 @@ baseMapOnly |> GenericChart.toChartHTML
To control the features of the map, a `Geo` object is used that can be associtaed with a given chart using the `Chart.WithGeo` function.
Here is a map with all physical features enabled and styled, at a larger-scale 1:50m resolution:
*)
+open Plotly.NET.LayoutObjects
let myGeo =
Geo.init(
diff --git a/docs/5_1_geo-plots.fsx b/docs/5_1_geo-plots.fsx
index 71086dba7..cbf6e5a10 100644
--- a/docs/5_1_geo-plots.fsx
+++ b/docs/5_1_geo-plots.fsx
@@ -52,6 +52,8 @@ The simplest type of geo plot is plotting the (lon,lat) pairs of a location via
Here is an example using the location of Canadian cities:
*)
+open Plotly.NET.LayoutObjects
+
let pointGeo =
Chart.PointGeo(
lon,
diff --git a/docs/5_2_choropleth-map.fsx b/docs/5_2_choropleth-map.fsx
index e5057251b..e260e9d62 100644
--- a/docs/5_2_choropleth-map.fsx
+++ b/docs/5_2_choropleth-map.fsx
@@ -112,6 +112,9 @@ choroplethMap1 |> GenericChart.toChartHTML
you can access various map styles via `Chart.withGeoStyle`, such as the projection type, lake/ocean color, and so on.
*)
+
+open Plotly.NET.LayoutObjects
+
let choroplethMap2 =
Chart.ChoroplethMap(
locations,z,
diff --git a/docs/6_0_geo-vs-mapbox.fsx b/docs/6_0_geo-vs-mapbox.fsx
index 58ffefca8..89321d98f 100644
--- a/docs/6_0_geo-vs-mapbox.fsx
+++ b/docs/6_0_geo-vs-mapbox.fsx
@@ -50,6 +50,7 @@ Mapbox tile maps are composed of various layers, of three different types:
a `Mapbox` object where these properties can be set can be initialized via `Mapbox.init`. To use it in a chart, use the `Chart.withMapbox` function:
*)
open Plotly.NET
+open Plotly.NET.LayoutObjects
// a simple Mapbox with a OpenStreetMap base layer.
let mb =
diff --git a/docs/6_1_mapbox-plots.fsx b/docs/6_1_mapbox-plots.fsx
index 7ce825b70..2eea6656f 100644
--- a/docs/6_1_mapbox-plots.fsx
+++ b/docs/6_1_mapbox-plots.fsx
@@ -51,6 +51,7 @@ let lat = [
The simplest type of geographic plot using Mapbox is plotting the (lon,lat) pairs of a location via `Chart.PointMapbox`.
Here is an example using the location of Canadian cities:
*)
+open Plotly.NET.LayoutObjects
let pointMapbox =
Chart.PointMapbox(
diff --git a/docs/6_2_choropleth-mapbox.fsx b/docs/6_2_choropleth-mapbox.fsx
index c40bf3f52..e32ad1fa0 100644
--- a/docs/6_2_choropleth-mapbox.fsx
+++ b/docs/6_2_choropleth-mapbox.fsx
@@ -124,6 +124,7 @@ And finally put together the chart using GeoJSON:
*)
open Plotly.NET
+open Plotly.NET.LayoutObjects
let choroplethMapbox =
Chart.ChoroplethMapbox(
diff --git a/docs/6_3_density-mapbox.fsx b/docs/6_3_density-mapbox.fsx
index 6825ad79f..4d7f6e31d 100644
--- a/docs/6_3_density-mapbox.fsx
+++ b/docs/6_3_density-mapbox.fsx
@@ -50,6 +50,7 @@ let lat= dataDensityMapbox.["Latitude"] |> Series.values
let magnitudes = dataDensityMapbox.["Magnitude"] |> Series.values
open Plotly.NET
+open Plotly.NET.LayoutObjects
let densityMapbox =
Chart.DensityMapbox(
diff --git a/docs/7_0_candlestick.fsx b/docs/7_0_candlestick.fsx
index f83c940fb..2e4797b6e 100644
--- a/docs/7_0_candlestick.fsx
+++ b/docs/7_0_candlestick.fsx
@@ -33,6 +33,8 @@ let's first create some data for the purpose of creating example charts:
*)
open Plotly.NET
+open Plotly.NET.LayoutObjects
+open Plotly.NET.TraceObjects
let candles =
[|("2020-01-17T13:40:00", 0.68888, 0.68888, 0.68879, 0.6888);
diff --git a/docs/7_1_funnel.fsx b/docs/7_1_funnel.fsx
index 6b09bc46c..09f3cf997 100644
--- a/docs/7_1_funnel.fsx
+++ b/docs/7_1_funnel.fsx
@@ -42,6 +42,7 @@ it traversed. See also the [FunnelArea]({{root}}/6_2_funnel_area.html) chart for
*)
open Plotly.NET
+open Plotly.NET.TraceObjects
// Customize the connector lines used to connect the funnel bars
let connectorLine = Line.init (Color="royalblue", Dash=StyleParam.DrawingStyle.Dot, Width=3.)
diff --git a/docs/8_1_polar_bar_charts.fsx b/docs/8_1_polar_bar_charts.fsx
index 8c8e49a99..dfc321113 100644
--- a/docs/8_1_polar_bar_charts.fsx
+++ b/docs/8_1_polar_bar_charts.fsx
@@ -50,7 +50,8 @@ A common use case is the **windrose chart**.
A wind rose is a graphic tool used by meteorologists to give a succinct view
of how wind speed and direction are typically distributed at a particular location.
*)
-
+open Plotly.NET.LayoutObjects
+
let windrose1 =
[
Chart.BarPolar (r , t, Name="11-14 m/s")
@@ -60,7 +61,7 @@ let windrose1 =
]
|> Chart.combine
|> Chart.withAngularAxis(
- Axis.AngularAxis.init(
+ AngularAxis.init(
CategoryOrder = StyleParam.CategoryOrder.Array,
CategoryArray = (["East"; "N-E"; "North"; "N-W"; "West"; "S-W"; "South"; "S-E";]) // set the order of the categorical axis
)
diff --git a/docs/8_2_styling_polar_layouts.fsx b/docs/8_2_styling_polar_layouts.fsx
index f7b69136c..2f455f588 100644
--- a/docs/8_2_styling_polar_layouts.fsx
+++ b/docs/8_2_styling_polar_layouts.fsx
@@ -66,6 +66,7 @@ combinedPolar |> GenericChart.toChartHTML
Use the `Chart.withPolar` function and initialize a Polar layout with the desired looks
*)
+open Plotly.NET.LayoutObjects
let styledPolar =
combinedPolar
@@ -95,12 +96,12 @@ You could pass these axes to `Chart.withPolar`, but for the case where you want
let styledPolar2 =
styledPolar
|> Chart.withAngularAxis(
- Axis.AngularAxis.init(
+ AngularAxis.init(
Color="darkblue"
)
)
|> Chart.withRadialAxis(
- Axis.RadialAxis.init(
+ RadialAxis.init(
Title = Title.init("Hi, i am the radial axis"),
Color="darkblue",
SeparateThousands = true
diff --git a/docs/9_0_parallel-categories.fsx b/docs/9_0_parallel-categories.fsx
index 24d05c47b..e30decad0 100644
--- a/docs/9_0_parallel-categories.fsx
+++ b/docs/9_0_parallel-categories.fsx
@@ -34,6 +34,7 @@ The parallel categories diagram (also known as parallel sets or alluvial diagram
Combinations of category rectangles across dimensions are connected by ribbons, where the height of the ribbon corresponds to the relative frequency of occurrence of the combination of categories in the data set.
*)
open Plotly.NET
+open Plotly.NET.TraceObjects
let dims =
[
diff --git a/docs/9_1_parallel-coords.fsx b/docs/9_1_parallel-coords.fsx
index 41695e1a1..d5b70d83c 100644
--- a/docs/9_1_parallel-coords.fsx
+++ b/docs/9_1_parallel-coords.fsx
@@ -64,6 +64,8 @@ parcoords1
parcoords1 |> GenericChart.toChartHTML
(***include-it-raw***)
+open Plotly.NET.TraceObjects
+
// Dynamic object version
let parcoords =
let v = [|
diff --git a/docs/index.fsx b/docs/index.fsx
index 8b2b03fac..94c35fa4f 100644
--- a/docs/index.fsx
+++ b/docs/index.fsx
@@ -235,15 +235,17 @@ static void Main(string[] args)
### Declarative style in F# using the underlying `DynamicObj`:
*)
+open Plotly.NET.LayoutObjects
+
let xAxis =
- let tmp = Axis.LinearAxis()
+ let tmp = LinearAxis()
tmp?title <- "xAxis"
tmp?showgrid <- false
tmp?showline <- true
tmp
let yAxis =
- let tmp = Axis.LinearAxis()
+ let tmp = LinearAxis()
tmp?title <- "yAxis"
tmp?showgrid <- false
tmp?showline <- true
diff --git a/src/Plotly.NET/Axis.fs b/src/Plotly.NET/Axis.fs
deleted file mode 100644
index 91848b25a..000000000
--- a/src/Plotly.NET/Axis.fs
+++ /dev/null
@@ -1,1372 +0,0 @@
-namespace Plotly.NET
-
-open DynamicObj
-open System
-
-/// Various axes that can be used to add scales to your plots.
-module Axis =
-
- /// Linear axes can be used as x and y scales on 2D plots, and as x,y, and z scales on 3D plots.
- type LinearAxis () =
- inherit DynamicObj ()
-
- ///
- /// Initialize a LinearAxis object that can be used as a positional scale for Y, X or Z coordinates.
- ///
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Sets the axis title.
- /// Sets the axis type. By default, plotly attempts to determined the axis type by looking into the data of the traces that referenced the axis in question.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Determines whether or not the range of this axis is computed in relation to the input data. See `rangemode` for more info. If `range` is provided, then `autorange` is set to "false".
- /// If "normal", the range is computed in relation to the extrema of the input data. If "tozero"`, the range extends to 0, regardless of the input data If "nonnegative", the range is non-negative, regardless of the input data. Applies only to linear axes.
- /// Sets the range of this axis. If the axis `type` is "log", then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axis `type` is "date", it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axis `type` is "category", it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Determines whether or not this axis is zoom-able. If true, then zoom is disabled.
- /// If set to another axis id (e.g. `x2`, `y`), the range of this axis changes together with the range of the corresponding axis such that the scale of pixels per unit is in a constant ratio. Both axes are still zoomable, but when you zoom one, the other will zoom the same amount, keeping a fixed midpoint. `constrain` and `constraintoward` determine how we enforce the constraint. You can chain these, ie `yaxis: {scaleanchor: "x"}, xaxis2: {scaleanchor: "y"}` but you can only link axes of the same `type`. The linked axis can have the opposite letter (to constrain the aspect ratio) or the same letter (to match scales across subplots). Loops (`yaxis: {scaleanchor: "x"}, xaxis: {scaleanchor: "y"}` or longer) are redundant and the last constraint encountered will be ignored to avoid possible inconsistent constraints via `scaleratio`. Note that setting axes simultaneously in both a `scaleanchor` and a `matches` constraint is currently forbidden.
- /// If this axis is linked to another by `scaleanchor`, this determines the pixel to unit scale ratio. For example, if this value is 10, then every unit on this axis spans 10 times the number of pixels as a unit on the linked axis. Use this for example to create an elevation profile where the vertical scale is exaggerated a fixed amount with respect to the horizontal.
- /// If this axis needs to be compressed (either due to its own `scaleanchor` and `scaleratio` or those of the other axis), determines how that happens: by increasing the "range", or by decreasing the "domain". Default is "domain" for axes containing image traces, "range" otherwise.
- /// If this axis needs to be compressed (either due to its own `scaleanchor` and `scaleratio` or those of the other axis), determines which direction we push the originally specified plot area. Options are "left", "center" (default), and "right" for x axes, and "top", "middle" (default), and "bottom" for y axes.
- /// If set to another axis id (e.g. `x2`, `y`), the range of this axis will match the range of the corresponding axis in data-coordinates space. Moreover, matching axes share auto-range values, category lists and histogram auto-bins. Note that setting axes simultaneously in both a `scaleanchor` and a `matches` constraint is currently forbidden. Moreover, note that matching axes must have the same `type`.
- /// Sets breaks in the axis range
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Determines where ticks and grid lines are drawn with respect to their corresponding tick labels. Only has an effect for axes of `type` "category" or "multicategory". When set to "boundaries", ticks and grid lines are drawn half a category to the left/bottom of labels.
- /// Determines where tick labels are drawn with respect to their corresponding ticks and grid lines. Only has an effect for axes of `type` "date" When set to "period", tick labels are drawn in the middle of the period between ticks.
- /// Determines where tick labels are drawn with respect to the axis Please note that top or bottom has no effect on x axes or when `ticklabelmode` is set to "period". Similarly left or right has no effect on y axes or when `ticklabelmode` is set to "period". Has no effect on "multicategory" axes or when `tickson` is set to "boundaries". When used on axes linked by `matches` or `scaleanchor`, no extra padding for inside labels would be added by autorange, so that the scales could match.
- /// Determines how we handle tick labels that would overflow either the graph div or the domain of the axis. The default value for inside tick labels is "hide past domain". Otherwise on "category" and "multicategory" axes the default is "allow". In other cases the default is "hide past div".
- /// Determines if the axis lines or/and ticks are mirrored to the opposite side of the plotting area. If "true", the axis lines are mirrored. If "ticks", the axis lines and ticks are mirrored. If "false", mirroring is disable. If "all", axis lines are mirrored on all shared-axes subplots. If "allticks", axis lines and ticks are mirrored on all shared-axes subplots.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// Determines whether long tick labels automatically grow the figure margins.
- /// Determines whether or not spikes (aka droplines) are drawn for this axis. Note: This only takes affect when hovermode = closest
- /// Sets the spike color. If undefined, will use the series color
- /// Sets the width (in px) of the zero line.
- /// Sets the dash style of lines
- /// Determines the drawing mode for the spike line If "toaxis", the line is drawn from the data point to the axis the series is plotted on. If "across", the line is drawn across the entire plot area, and supercedes "toaxis". If "marker", then a marker dot is drawn on the axis the series is plotted on
- /// Determines whether spikelines are stuck to the cursor or to the closest datapoints.
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Determines whether or not a line is drawn at along the 0 value of this axis. If "true", the zero line is drawn on top of the grid lines.
- /// Sets the line color of the zero line.
- /// Sets the width (in px) of the zero line.
- /// Determines whether or not a dividers are drawn between the category levels of this axis. Only has an effect on "multicategory" axes.
- /// Sets the color of the dividers Only has an effect on "multicategory" axes.
- /// Sets the width (in px) of the dividers Only has an effect on "multicategory" axes.
- /// If set to an opposite-letter axis id (e.g. `x2`, `y`), this axis is bound to the corresponding opposite-letter axis. If set to "free", this axis' position is determined by `position`.
- /// Determines whether a x (y) axis is positioned at the "bottom" ("left") or "top" ("right") of the plotting area.
- /// If set a same-letter axis id, this axis is overlaid on top of the corresponding same-letter axis, with traces and axes visible for both axes. If "false", this axis does not overlay any same-letter axes. In this case, for axes with overlapping domains only the highest-numbered axis will be visible.
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- /// Sets the domain of this axis (in plot fraction).
- /// Sets the position of this axis in the plotting space (in normalized coordinates). Only has an effect if `anchor` is set to "free".
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Controls persistence of user-driven changes in axis `range`, `autorange`, and `title` if in `editable: true` configuration. Defaults to `layout.uirevision`.
- /// Sets a range slider for this axis
- /// Sets a range selector for this axis. This object contains toggable presets for the rangeslider.
- /// Sets the calendar system to use for `range` and `tick0` if this is a date axis. This does not set the calendar for interpreting data on this axis, that's specified in the trace or via the global `layout.calendar`
- static member init
- (
- ?Visible : bool,
- ?Color : string,
- ?Title : Title,
- ?AxisType : StyleParam.AxisType,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?AutoRange : StyleParam.AutoRange,
- ?RangeMode : StyleParam.RangeMode,
- ?Range : StyleParam.Range,
- ?FixedRange : bool,
- ?ScaleAnchor : StyleParam.LinearAxisId,
- ?ScaleRatio : float,
- ?Constrain : StyleParam.AxisConstraint,
- ?ConstrainToward : StyleParam.AxisConstraintDirection,
- ?Matches : StyleParam.LinearAxisId,
- ?Rangebreaks : seq,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TicksOn : StyleParam.CategoryTickAnchor,
- ?TickLabelMode : StyleParam.TickLabelMode,
- ?TickLabelPosition : StyleParam.TickLabelPosition,
- ?TickLabelOverflow : StyleParam.TickLabelOverflow,
- ?Mirror : StyleParam.Mirror,
- ?TickLen : float,
- ?TickWidth : float,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?AutoMargin : bool,
- ?ShowSpikes : bool,
- ?SpikeColor : string,
- ?SpikeThickness : int,
- ?SpikeDash : StyleParam.DrawingStyle,
- ?SpikeMode : StyleParam.SpikeMode,
- ?SpikeSnap : StyleParam.SpikeSnap,
- ?TickFont : Font,
- ?TickAngle : int,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?HoverFormat : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : float,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : float,
- ?ZeroLine : bool,
- ?ZeroLineColor : string,
- ?ZeroLineWidth : float,
- ?ShowDividers : bool,
- ?DividerColor : string,
- ?DividerWidth : int,
- ?Anchor : StyleParam.LinearAxisId,
- ?Side : StyleParam.Side,
- ?Overlaying : StyleParam.LinearAxisId,
- ?Layer : StyleParam.Layer,
- ?Domain : StyleParam.Range,
- ?Position : float,
- ?CategoryOrder : StyleParam.CategoryOrder,
- ?CategoryArray : seq<#IConvertible>,
- ?UIRevision : #IConvertible,
- ?RangeSlider : RangeSlider,
- ?RangeSelector : RangeSelector,
- ?Calendar : StyleParam.Calendar
-
- ) =
- LinearAxis()
- |> LinearAxis.style
- (
- ?Visible = Visible ,
- ?Color = Color ,
- ?Title = Title ,
- ?AxisType = AxisType ,
- ?AutoTypeNumbers = AutoTypeNumbers ,
- ?AutoRange = AutoRange ,
- ?RangeMode = RangeMode ,
- ?Range = Range ,
- ?FixedRange = FixedRange ,
- ?ScaleAnchor = ScaleAnchor ,
- ?ScaleRatio = ScaleRatio ,
- ?Constrain = Constrain ,
- ?ConstrainToward = ConstrainToward ,
- ?Matches = Matches ,
- ?Rangebreaks = Rangebreaks ,
- ?TickMode = TickMode ,
- ?NTicks = NTicks ,
- ?Tick0 = Tick0 ,
- ?DTick = DTick ,
- ?TickVals = TickVals ,
- ?TickText = TickText ,
- ?Ticks = Ticks ,
- ?TicksOn = TicksOn ,
- ?TickLabelMode = TickLabelMode ,
- ?TickLabelPosition = TickLabelPosition ,
- ?TickLabelOverflow = TickLabelOverflow ,
- ?Mirror = Mirror ,
- ?TickLen = TickLen ,
- ?TickWidth = TickWidth ,
- ?TickColor = TickColor ,
- ?ShowTickLabels = ShowTickLabels ,
- ?AutoMargin = AutoMargin ,
- ?ShowSpikes = ShowSpikes ,
- ?SpikeColor = SpikeColor ,
- ?SpikeThickness = SpikeThickness ,
- ?SpikeDash = SpikeDash ,
- ?SpikeMode = SpikeMode ,
- ?SpikeSnap = SpikeSnap ,
- ?TickFont = TickFont ,
- ?TickAngle = TickAngle ,
- ?ShowTickPrefix = ShowTickPrefix ,
- ?TickPrefix = TickPrefix ,
- ?ShowTickSuffix = ShowTickSuffix ,
- ?TickSuffix = TickSuffix ,
- ?ShowExponent = ShowExponent ,
- ?ExponentFormat = ExponentFormat ,
- ?MinExponent = MinExponent ,
- ?SeparateThousands = SeparateThousands ,
- ?TickFormat = TickFormat ,
- ?TickFormatStops = TickFormatStops ,
- ?HoverFormat = HoverFormat ,
- ?ShowLine = ShowLine ,
- ?LineColor = LineColor ,
- ?LineWidth = LineWidth ,
- ?ShowGrid = ShowGrid ,
- ?GridColor = GridColor ,
- ?GridWidth = GridWidth ,
- ?ZeroLine = ZeroLine ,
- ?ZeroLineColor = ZeroLineColor ,
- ?ZeroLineWidth = ZeroLineWidth ,
- ?ShowDividers = ShowDividers ,
- ?DividerColor = DividerColor ,
- ?DividerWidth = DividerWidth ,
- ?Anchor = Anchor ,
- ?Side = Side ,
- ?Overlaying = Overlaying ,
- ?Layer = Layer ,
- ?Domain = Domain ,
- ?Position = Position ,
- ?CategoryOrder = CategoryOrder ,
- ?CategoryArray = CategoryArray ,
- ?UIRevision = UIRevision ,
- ?RangeSlider = RangeSlider ,
- ?RangeSelector = RangeSelector ,
- ?Calendar = Calendar
- )
-
- ///
- /// Initialize a categorical LinearAxis object that can be used as a positional scale for Y, X or Z coordinates.
- ///
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Sets the axis title.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Determines whether or not the range of this axis is computed in relation to the input data. See `rangemode` for more info. If `range` is provided, then `autorange` is set to "false".
- /// If "normal", the range is computed in relation to the extrema of the input data. If "tozero"`, the range extends to 0, regardless of the input data If "nonnegative", the range is non-negative, regardless of the input data. Applies only to linear axes.
- /// Sets the range of this axis. If the axis `type` is "log", then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axis `type` is "date", it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axis `type` is "category", it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Determines whether or not this axis is zoom-able. If true, then zoom is disabled.
- /// If set to another axis id (e.g. `x2`, `y`), the range of this axis changes together with the range of the corresponding axis such that the scale of pixels per unit is in a constant ratio. Both axes are still zoomable, but when you zoom one, the other will zoom the same amount, keeping a fixed midpoint. `constrain` and `constraintoward` determine how we enforce the constraint. You can chain these, ie `yaxis: {scaleanchor: "x"}, xaxis2: {scaleanchor: "y"}` but you can only link axes of the same `type`. The linked axis can have the opposite letter (to constrain the aspect ratio) or the same letter (to match scales across subplots). Loops (`yaxis: {scaleanchor: "x"}, xaxis: {scaleanchor: "y"}` or longer) are redundant and the last constraint encountered will be ignored to avoid possible inconsistent constraints via `scaleratio`. Note that setting axes simultaneously in both a `scaleanchor` and a `matches` constraint is currently forbidden.
- /// If this axis is linked to another by `scaleanchor`, this determines the pixel to unit scale ratio. For example, if this value is 10, then every unit on this axis spans 10 times the number of pixels as a unit on the linked axis. Use this for example to create an elevation profile where the vertical scale is exaggerated a fixed amount with respect to the horizontal.
- /// If this axis needs to be compressed (either due to its own `scaleanchor` and `scaleratio` or those of the other axis), determines how that happens: by increasing the "range", or by decreasing the "domain". Default is "domain" for axes containing image traces, "range" otherwise.
- /// If this axis needs to be compressed (either due to its own `scaleanchor` and `scaleratio` or those of the other axis), determines which direction we push the originally specified plot area. Options are "left", "center" (default), and "right" for x axes, and "top", "middle" (default), and "bottom" for y axes.
- /// If set to another axis id (e.g. `x2`, `y`), the range of this axis will match the range of the corresponding axis in data-coordinates space. Moreover, matching axes share auto-range values, category lists and histogram auto-bins. Note that setting axes simultaneously in both a `scaleanchor` and a `matches` constraint is currently forbidden. Moreover, note that matching axes must have the same `type`.
- /// Sets breaks in the axis range
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Determines where ticks and grid lines are drawn with respect to their corresponding tick labels. Only has an effect for axes of `type` "category" or "multicategory". When set to "boundaries", ticks and grid lines are drawn half a category to the left/bottom of labels.
- /// Determines where tick labels are drawn with respect to their corresponding ticks and grid lines. Only has an effect for axes of `type` "date" When set to "period", tick labels are drawn in the middle of the period between ticks.
- /// Determines where tick labels are drawn with respect to the axis Please note that top or bottom has no effect on x axes or when `ticklabelmode` is set to "period". Similarly left or right has no effect on y axes or when `ticklabelmode` is set to "period". Has no effect on "multicategory" axes or when `tickson` is set to "boundaries". When used on axes linked by `matches` or `scaleanchor`, no extra padding for inside labels would be added by autorange, so that the scales could match.
- /// Determines how we handle tick labels that would overflow either the graph div or the domain of the axis. The default value for inside tick labels is "hide past domain". Otherwise on "category" and "multicategory" axes the default is "allow". In other cases the default is "hide past div".
- /// Determines if the axis lines or/and ticks are mirrored to the opposite side of the plotting area. If "true", the axis lines are mirrored. If "ticks", the axis lines and ticks are mirrored. If "false", mirroring is disable. If "all", axis lines are mirrored on all shared-axes subplots. If "allticks", axis lines and ticks are mirrored on all shared-axes subplots.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// Determines whether long tick labels automatically grow the figure margins.
- /// Determines whether or not spikes (aka droplines) are drawn for this axis. Note: This only takes affect when hovermode = closest
- /// Sets the spike color. If undefined, will use the series color
- /// Sets the width (in px) of the zero line.
- /// Sets the dash style of lines
- /// Determines the drawing mode for the spike line If "toaxis", the line is drawn from the data point to the axis the series is plotted on. If "across", the line is drawn across the entire plot area, and supercedes "toaxis". If "marker", then a marker dot is drawn on the axis the series is plotted on
- /// Determines whether spikelines are stuck to the cursor or to the closest datapoints.
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Determines whether or not a line is drawn at along the 0 value of this axis. If "true", the zero line is drawn on top of the grid lines.
- /// Sets the line color of the zero line.
- /// Sets the width (in px) of the zero line.
- /// Determines whether or not a dividers are drawn between the category levels of this axis. Only has an effect on "multicategory" axes.
- /// Sets the color of the dividers Only has an effect on "multicategory" axes.
- /// Sets the width (in px) of the dividers Only has an effect on "multicategory" axes.
- /// If set to an opposite-letter axis id (e.g. `x2`, `y`), this axis is bound to the corresponding opposite-letter axis. If set to "free", this axis' position is determined by `position`.
- /// Determines whether a x (y) axis is positioned at the "bottom" ("left") or "top" ("right") of the plotting area.
- /// If set a same-letter axis id, this axis is overlaid on top of the corresponding same-letter axis, with traces and axes visible for both axes. If "false", this axis does not overlay any same-letter axes. In this case, for axes with overlapping domains only the highest-numbered axis will be visible.
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- /// Sets the domain of this axis (in plot fraction).
- /// Sets the position of this axis in the plotting space (in normalized coordinates). Only has an effect if `anchor` is set to "free".
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Controls persistence of user-driven changes in axis `range`, `autorange`, and `title` if in `editable: true` configuration. Defaults to `layout.uirevision`.
- /// Sets a range slider for this axis
- /// Sets a range selector for this axis. This object contains toggable presets for the rangeslider.
- /// Sets the calendar system to use for `range` and `tick0` if this is a date axis. This does not set the calendar for interpreting data on this axis, that's specified in the trace or via the global `layout.calendar`
- static member initCategorical
- (
- categoryOrder : StyleParam.CategoryOrder,
- ?Visible : bool,
- ?Color : string,
- ?Title : Title,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?AutoRange : StyleParam.AutoRange,
- ?RangeMode : StyleParam.RangeMode,
- ?Range : StyleParam.Range,
- ?FixedRange : bool,
- ?ScaleAnchor : StyleParam.LinearAxisId,
- ?ScaleRatio : float,
- ?Constrain : StyleParam.AxisConstraint,
- ?ConstrainToward : StyleParam.AxisConstraintDirection,
- ?Matches : StyleParam.LinearAxisId,
- ?Rangebreaks : seq,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TicksOn : StyleParam.CategoryTickAnchor,
- ?TickLabelMode : StyleParam.TickLabelMode,
- ?TickLabelPosition : StyleParam.TickLabelPosition,
- ?TickLabelOverflow : StyleParam.TickLabelOverflow,
- ?Mirror : StyleParam.Mirror,
- ?TickLen : float,
- ?TickWidth : float,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?AutoMargin : bool,
- ?ShowSpikes : bool,
- ?SpikeColor : string,
- ?SpikeThickness : int,
- ?SpikeDash : StyleParam.DrawingStyle,
- ?SpikeMode : StyleParam.SpikeMode,
- ?SpikeSnap : StyleParam.SpikeSnap,
- ?TickFont : Font,
- ?TickAngle : int,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?HoverFormat : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : float,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : float,
- ?ZeroLine : bool,
- ?ZeroLineColor : string,
- ?ZeroLineWidth : float,
- ?ShowDividers : bool,
- ?DividerColor : string,
- ?DividerWidth : int,
- ?Anchor : StyleParam.LinearAxisId,
- ?Side : StyleParam.Side,
- ?Overlaying : StyleParam.LinearAxisId,
- ?Layer : StyleParam.Layer,
- ?Domain : StyleParam.Range,
- ?Position : float,
- ?CategoryArray : seq<#IConvertible>,
- ?UIRevision : #IConvertible,
- ?RangeSlider : RangeSlider,
- ?RangeSelector : RangeSelector,
- ?Calendar : StyleParam.Calendar
- ) =
- LinearAxis()
- |> LinearAxis.style
- (
- CategoryOrder = categoryOrder,
- AxisType = StyleParam.AxisType.Category,
- ?Visible = Visible ,
- ?Color = Color ,
- ?Title = Title ,
- ?AutoTypeNumbers = AutoTypeNumbers ,
- ?AutoRange = AutoRange ,
- ?RangeMode = RangeMode ,
- ?Range = Range ,
- ?FixedRange = FixedRange ,
- ?ScaleAnchor = ScaleAnchor ,
- ?ScaleRatio = ScaleRatio ,
- ?Constrain = Constrain ,
- ?ConstrainToward = ConstrainToward ,
- ?Matches = Matches ,
- ?Rangebreaks = Rangebreaks ,
- ?TickMode = TickMode ,
- ?NTicks = NTicks ,
- ?Tick0 = Tick0 ,
- ?DTick = DTick ,
- ?TickVals = TickVals ,
- ?TickText = TickText ,
- ?Ticks = Ticks ,
- ?TicksOn = TicksOn ,
- ?TickLabelMode = TickLabelMode ,
- ?TickLabelPosition = TickLabelPosition ,
- ?TickLabelOverflow = TickLabelOverflow ,
- ?Mirror = Mirror ,
- ?TickLen = TickLen ,
- ?TickWidth = TickWidth ,
- ?TickColor = TickColor ,
- ?ShowTickLabels = ShowTickLabels ,
- ?AutoMargin = AutoMargin ,
- ?ShowSpikes = ShowSpikes ,
- ?SpikeColor = SpikeColor ,
- ?SpikeThickness = SpikeThickness ,
- ?SpikeDash = SpikeDash ,
- ?SpikeMode = SpikeMode ,
- ?SpikeSnap = SpikeSnap ,
- ?TickFont = TickFont ,
- ?TickAngle = TickAngle ,
- ?ShowTickPrefix = ShowTickPrefix ,
- ?TickPrefix = TickPrefix ,
- ?ShowTickSuffix = ShowTickSuffix ,
- ?TickSuffix = TickSuffix ,
- ?ShowExponent = ShowExponent ,
- ?ExponentFormat = ExponentFormat ,
- ?MinExponent = MinExponent ,
- ?SeparateThousands = SeparateThousands ,
- ?TickFormat = TickFormat ,
- ?TickFormatStops = TickFormatStops ,
- ?HoverFormat = HoverFormat ,
- ?ShowLine = ShowLine ,
- ?LineColor = LineColor ,
- ?LineWidth = LineWidth ,
- ?ShowGrid = ShowGrid ,
- ?GridColor = GridColor ,
- ?GridWidth = GridWidth ,
- ?ZeroLine = ZeroLine ,
- ?ZeroLineColor = ZeroLineColor ,
- ?ZeroLineWidth = ZeroLineWidth ,
- ?ShowDividers = ShowDividers ,
- ?DividerColor = DividerColor ,
- ?DividerWidth = DividerWidth ,
- ?Anchor = Anchor ,
- ?Side = Side ,
- ?Overlaying = Overlaying ,
- ?Layer = Layer ,
- ?Domain = Domain ,
- ?Position = Position ,
- ?CategoryArray = CategoryArray ,
- ?UIRevision = UIRevision ,
- ?RangeSlider = RangeSlider ,
- ?RangeSelector = RangeSelector ,
- ?Calendar = Calendar
- )
-
- ///
- /// Create a function that applies the given style parameters to a LinearAxis object
- ///
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Sets the axis title.
- /// Sets the axis type. By default, plotly attempts to determined the axis type by looking into the data of the traces that referenced the axis in question.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Determines whether or not the range of this axis is computed in relation to the input data. See `rangemode` for more info. If `range` is provided, then `autorange` is set to "false".
- /// If "normal", the range is computed in relation to the extrema of the input data. If "tozero"`, the range extends to 0, regardless of the input data If "nonnegative", the range is non-negative, regardless of the input data. Applies only to linear axes.
- /// Sets the range of this axis. If the axis `type` is "log", then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axis `type` is "date", it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axis `type` is "category", it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Determines whether or not this axis is zoom-able. If true, then zoom is disabled.
- /// If set to another axis id (e.g. `x2`, `y`), the range of this axis changes together with the range of the corresponding axis such that the scale of pixels per unit is in a constant ratio. Both axes are still zoomable, but when you zoom one, the other will zoom the same amount, keeping a fixed midpoint. `constrain` and `constraintoward` determine how we enforce the constraint. You can chain these, ie `yaxis: {scaleanchor: "x"}, xaxis2: {scaleanchor: "y"}` but you can only link axes of the same `type`. The linked axis can have the opposite letter (to constrain the aspect ratio) or the same letter (to match scales across subplots). Loops (`yaxis: {scaleanchor: "x"}, xaxis: {scaleanchor: "y"}` or longer) are redundant and the last constraint encountered will be ignored to avoid possible inconsistent constraints via `scaleratio`. Note that setting axes simultaneously in both a `scaleanchor` and a `matches` constraint is currently forbidden.
- /// If this axis is linked to another by `scaleanchor`, this determines the pixel to unit scale ratio. For example, if this value is 10, then every unit on this axis spans 10 times the number of pixels as a unit on the linked axis. Use this for example to create an elevation profile where the vertical scale is exaggerated a fixed amount with respect to the horizontal.
- /// If this axis needs to be compressed (either due to its own `scaleanchor` and `scaleratio` or those of the other axis), determines how that happens: by increasing the "range", or by decreasing the "domain". Default is "domain" for axes containing image traces, "range" otherwise.
- /// If this axis needs to be compressed (either due to its own `scaleanchor` and `scaleratio` or those of the other axis), determines which direction we push the originally specified plot area. Options are "left", "center" (default), and "right" for x axes, and "top", "middle" (default), and "bottom" for y axes.
- /// If set to another axis id (e.g. `x2`, `y`), the range of this axis will match the range of the corresponding axis in data-coordinates space. Moreover, matching axes share auto-range values, category lists and histogram auto-bins. Note that setting axes simultaneously in both a `scaleanchor` and a `matches` constraint is currently forbidden. Moreover, note that matching axes must have the same `type`.
- /// Sets breaks in the axis range
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Determines where ticks and grid lines are drawn with respect to their corresponding tick labels. Only has an effect for axes of `type` "category" or "multicategory". When set to "boundaries", ticks and grid lines are drawn half a category to the left/bottom of labels.
- /// Determines where tick labels are drawn with respect to their corresponding ticks and grid lines. Only has an effect for axes of `type` "date" When set to "period", tick labels are drawn in the middle of the period between ticks.
- /// Determines where tick labels are drawn with respect to the axis Please note that top or bottom has no effect on x axes or when `ticklabelmode` is set to "period". Similarly left or right has no effect on y axes or when `ticklabelmode` is set to "period". Has no effect on "multicategory" axes or when `tickson` is set to "boundaries". When used on axes linked by `matches` or `scaleanchor`, no extra padding for inside labels would be added by autorange, so that the scales could match.
- /// Determines how we handle tick labels that would overflow either the graph div or the domain of the axis. The default value for inside tick labels is "hide past domain". Otherwise on "category" and "multicategory" axes the default is "allow". In other cases the default is "hide past div".
- /// Determines if the axis lines or/and ticks are mirrored to the opposite side of the plotting area. If "true", the axis lines are mirrored. If "ticks", the axis lines and ticks are mirrored. If "false", mirroring is disable. If "all", axis lines are mirrored on all shared-axes subplots. If "allticks", axis lines and ticks are mirrored on all shared-axes subplots.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// Determines whether long tick labels automatically grow the figure margins.
- /// Determines whether or not spikes (aka droplines) are drawn for this axis. Note: This only takes affect when hovermode = closest
- /// Sets the spike color. If undefined, will use the series color
- /// Sets the width (in px) of the zero line.
- /// Sets the dash style of lines
- /// Determines the drawing mode for the spike line If "toaxis", the line is drawn from the data point to the axis the series is plotted on. If "across", the line is drawn across the entire plot area, and supercedes "toaxis". If "marker", then a marker dot is drawn on the axis the series is plotted on
- /// Determines whether spikelines are stuck to the cursor or to the closest datapoints.
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Determines whether or not a line is drawn at along the 0 value of this axis. If "true", the zero line is drawn on top of the grid lines.
- /// Sets the line color of the zero line.
- /// Sets the width (in px) of the zero line.
- /// Determines whether or not a dividers are drawn between the category levels of this axis. Only has an effect on "multicategory" axes.
- /// Sets the color of the dividers Only has an effect on "multicategory" axes.
- /// Sets the width (in px) of the dividers Only has an effect on "multicategory" axes.
- /// If set to an opposite-letter axis id (e.g. `x2`, `y`), this axis is bound to the corresponding opposite-letter axis. If set to "free", this axis' position is determined by `position`.
- /// Determines whether a x (y) axis is positioned at the "bottom" ("left") or "top" ("right") of the plotting area.
- /// If set a same-letter axis id, this axis is overlaid on top of the corresponding same-letter axis, with traces and axes visible for both axes. If "false", this axis does not overlay any same-letter axes. In this case, for axes with overlapping domains only the highest-numbered axis will be visible.
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- /// Sets the domain of this axis (in plot fraction).
- /// Sets the position of this axis in the plotting space (in normalized coordinates). Only has an effect if `anchor` is set to "free".
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Controls persistence of user-driven changes in axis `range`, `autorange`, and `title` if in `editable: true` configuration. Defaults to `layout.uirevision`.
- /// Sets a range slider for this axis
- /// Sets a range selector for this axis. This object contains toggable presets for the rangeslider.
- /// Sets the calendar system to use for `range` and `tick0` if this is a date axis. This does not set the calendar for interpreting data on this axis, that's specified in the trace or via the global `layout.calendar`
- static member style
- (
- ?Visible : bool,
- ?Color : string,
- ?Title : Title,
- ?AxisType : StyleParam.AxisType,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?AutoRange : StyleParam.AutoRange,
- ?RangeMode : StyleParam.RangeMode,
- ?Range : StyleParam.Range,
- ?FixedRange : bool,
- ?ScaleAnchor : StyleParam.LinearAxisId,
- ?ScaleRatio : float,
- ?Constrain : StyleParam.AxisConstraint,
- ?ConstrainToward : StyleParam.AxisConstraintDirection,
- ?Matches : StyleParam.LinearAxisId,
- ?Rangebreaks : seq,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TicksOn : StyleParam.CategoryTickAnchor,
- ?TickLabelMode : StyleParam.TickLabelMode,
- ?TickLabelPosition : StyleParam.TickLabelPosition,
- ?TickLabelOverflow : StyleParam.TickLabelOverflow,
- ?Mirror : StyleParam.Mirror,
- ?TickLen : float,
- ?TickWidth : float,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?AutoMargin : bool,
- ?ShowSpikes : bool,
- ?SpikeColor : string,
- ?SpikeThickness : int,
- ?SpikeDash : StyleParam.DrawingStyle,
- ?SpikeMode : StyleParam.SpikeMode,
- ?SpikeSnap : StyleParam.SpikeSnap,
- ?TickFont : Font,
- ?TickAngle : int,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?HoverFormat : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : float,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : float,
- ?ZeroLine : bool,
- ?ZeroLineColor : string,
- ?ZeroLineWidth : float,
- ?ShowDividers : bool,
- ?DividerColor : string,
- ?DividerWidth : int,
- ?Anchor : StyleParam.LinearAxisId,
- ?Side : StyleParam.Side,
- ?Overlaying : StyleParam.LinearAxisId,
- ?Layer : StyleParam.Layer,
- ?Domain : StyleParam.Range,
- ?Position : float,
- ?CategoryOrder : StyleParam.CategoryOrder,
- ?CategoryArray : seq<#IConvertible>,
- ?UIRevision : #IConvertible,
- ?RangeSlider : RangeSlider,
- ?RangeSelector : RangeSelector,
- ?Calendar : StyleParam.Calendar
- ) =
- (fun (axis:LinearAxis) ->
-
- Visible |> DynObj.setValueOpt axis "visible"
- Color |> DynObj.setValueOpt axis "color"
- Title |> DynObj.setValueOpt axis "title"
- AxisType |> DynObj.setValueOptBy axis "axistype" StyleParam.AxisType.convert
- AutoTypeNumbers |> DynObj.setValueOptBy axis "autotypenumbers" StyleParam.AutoTypeNumbers.convert
- AutoRange |> DynObj.setValueOptBy axis "autorange" StyleParam.AutoRange.convert
- RangeMode |> DynObj.setValueOptBy axis "rangemode" StyleParam.RangeMode.convert
- Range |> DynObj.setValueOptBy axis "range" StyleParam.Range.convert
- FixedRange |> DynObj.setValueOpt axis "fixedrange"
- ScaleAnchor |> DynObj.setValueOptBy axis "scaleanchor" StyleParam.LinearAxisId.convert
- ScaleRatio |> DynObj.setValueOpt axis "scaleratio"
- Constrain |> DynObj.setValueOptBy axis "constrain" StyleParam.AxisConstraint.convert
- ConstrainToward |> DynObj.setValueOptBy axis "constraitoward" StyleParam.AxisConstraintDirection.convert
- Matches |> DynObj.setValueOptBy axis "matches" StyleParam.LinearAxisId.convert
- Rangebreaks |> DynObj.setValueOpt axis "rangebreaks"
- TickMode |> DynObj.setValueOptBy axis "tickmode" StyleParam.TickMode.convert
- NTicks |> DynObj.setValueOpt axis "nticks"
- Tick0 |> DynObj.setValueOpt axis "tick0"
- DTick |> DynObj.setValueOpt axis "dtick"
- TickVals |> DynObj.setValueOpt axis "tickvals"
- TickText |> DynObj.setValueOpt axis "ticktext"
- Ticks |> DynObj.setValueOptBy axis "ticks" StyleParam.TickOptions.convert
- TicksOn |> DynObj.setValueOptBy axis "tickson" StyleParam.CategoryTickAnchor.convert
- TickLabelMode |> DynObj.setValueOptBy axis "ticklabelmode" StyleParam.TickLabelMode.convert
- TickLabelPosition |> DynObj.setValueOptBy axis "ticklabelposition" StyleParam.TickLabelPosition.convert
- TickLabelOverflow |> DynObj.setValueOptBy axis "ticklabeloverflow" StyleParam.TickLabelOverflow.convert
- Mirror |> DynObj.setValueOptBy axis "mirror" StyleParam.Mirror.convert
- TickLen |> DynObj.setValueOpt axis "ticklen"
- TickWidth |> DynObj.setValueOpt axis "tickwidth"
- TickColor |> DynObj.setValueOpt axis "tickcolor"
- ShowTickLabels |> DynObj.setValueOpt axis "showticklabels"
- AutoMargin |> DynObj.setValueOpt axis "automargin"
- ShowSpikes |> DynObj.setValueOpt axis "showspikes"
- SpikeColor |> DynObj.setValueOpt axis "spikecolor"
- SpikeThickness |> DynObj.setValueOpt axis "spikethickness"
- SpikeDash |> DynObj.setValueOptBy axis "spikedash" StyleParam.DrawingStyle.convert
- SpikeMode |> DynObj.setValueOptBy axis "spikemode" StyleParam.SpikeMode.convert
- SpikeSnap |> DynObj.setValueOptBy axis "spikesnap" StyleParam.SpikeSnap.convert
- TickFont |> DynObj.setValueOpt axis "tickfont"
- TickAngle |> DynObj.setValueOpt axis "tickangle"
- ShowTickPrefix |> DynObj.setValueOptBy axis "showtickprefix" StyleParam.ShowTickOption.convert
- TickPrefix |> DynObj.setValueOpt axis "tickprefix"
- ShowTickSuffix |> DynObj.setValueOptBy axis "showticksuffix" StyleParam.ShowTickOption.convert
- TickSuffix |> DynObj.setValueOpt axis "ticksuffix"
- ShowExponent |> DynObj.setValueOptBy axis "showexponent" StyleParam.ShowExponent.convert
- ExponentFormat |> DynObj.setValueOptBy axis "exponentformat" StyleParam.ExponentFormat.convert
- MinExponent |> DynObj.setValueOpt axis "minexponent"
- SeparateThousands |> DynObj.setValueOpt axis "separatethousands"
- TickFormat |> DynObj.setValueOpt axis "tickformat"
- TickFormatStops |> DynObj.setValueOpt axis "tickformatstops"
- HoverFormat |> DynObj.setValueOpt axis "hoverformat"
- ShowLine |> DynObj.setValueOpt axis "showline"
- LineColor |> DynObj.setValueOpt axis "linecolor"
- LineWidth |> DynObj.setValueOpt axis "linewidth"
- ShowGrid |> DynObj.setValueOpt axis "showgrid"
- GridColor |> DynObj.setValueOpt axis "gridcolor"
- GridWidth |> DynObj.setValueOpt axis "gridwidth"
- ZeroLine |> DynObj.setValueOpt axis "zeroline"
- ZeroLineColor |> DynObj.setValueOpt axis "zerolinecolor"
- ZeroLineWidth |> DynObj.setValueOpt axis "zerolinewidth"
- ShowDividers |> DynObj.setValueOpt axis "showdividers"
- DividerColor |> DynObj.setValueOpt axis "dividercolor"
- DividerWidth |> DynObj.setValueOpt axis "dividerwidth"
- Anchor |> DynObj.setValueOptBy axis "anchor" StyleParam.LinearAxisId.convert
- Side |> DynObj.setValueOptBy axis "side" StyleParam.Side.convert
- Overlaying |> DynObj.setValueOptBy axis "overlaying" StyleParam.LinearAxisId.convert
- Layer |> DynObj.setValueOptBy axis "layer" StyleParam.Layer.convert
- Domain |> DynObj.setValueOptBy axis "domain" StyleParam.Range.convert
- Position |> DynObj.setValueOpt axis "position"
- CategoryOrder |> DynObj.setValueOptBy axis "categoryorder" StyleParam.CategoryOrder.convert
- CategoryArray |> DynObj.setValueOpt axis "categoryarray"
- UIRevision |> DynObj.setValueOpt axis "uirevision"
- RangeSlider |> DynObj.setValueOpt axis "rangeslider"
- RangeSelector |> DynObj.setValueOpt axis "rangeselector"
- Calendar |> DynObj.setValueOptBy axis "calendar" StyleParam.Calendar.convert
-
- axis
- )
-
- /// Radial axes can be used as a scale for the radial coordinates in polar plots.
- type RadialAxis () =
- inherit DynamicObj ()
-
- ///
- /// Initialize an AngularAxis object that can be used as a angular scale for polar coordinates.
- ///
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets the angular axis type. If "linear", set `thetaunit` to determine the unit in which axis value are shown. If "category, use `period` to set the number of integer coordinates around polar axis.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Determines whether or not the range of this axis is computed in relation to the input data. See `rangemode` for more info. If `range` is provided, then `autorange` is set to "false".
- /// If "tozero"`, the range extends to 0, regardless of the input data If "nonnegative", the range is non-negative, regardless of the input data. If "normal", the range is computed in relation to the extrema of the input data (same behavior as for cartesian axes).
- /// Sets the range of this axis. If the axis `type` is "log", then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axis `type` is "date", it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axis `type` is "category", it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Sets the angle (in degrees) from which the radial axis is drawn. Note that by default, radial axis line on the theta=0 line corresponds to a line pointing right (like what mathematicians prefer). Defaults to the first `polar.sector` angle.
- /// Determines on which side of radial axis line the tick and tick labels appear.
- /// Sets the title of the Radial Axis.
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Controls persistence of user-driven changes in axis `rotation`. Defaults to `polar<N>.uirevision`.
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- /// Sets the calendar system to use for `range` and `tick0` if this is a date axis. This does not set the calendar for interpreting data on this axis, that's specified in the trace or via the global `layout.calendar`
- static member init
- (
- ?Visible : bool,
- ?AxisType : StyleParam.AxisType,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?AutoRange : StyleParam.AutoRange,
- ?RangeMode : StyleParam.RangeMode,
- ?Range : StyleParam.Range,
- ?CategoryOrder : StyleParam.CategoryOrder,
- ?CategoryArray : seq<#IConvertible>,
- ?Angle : float,
- ?Side : StyleParam.Direction,
- ?Title : Title,
- ?HoverFormat : string,
- ?UIRevision : #IConvertible,
- ?Color : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : int,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : int,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TickLen : int,
- ?TickWidth : int,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFont : Font,
- ?TickAngle : int,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?Layer : StyleParam.Layer,
- ?Calendar : StyleParam.Calendar
- ) =
- RadialAxis()
- |> RadialAxis.style
- (
- ?Visible = Visible ,
- ?AxisType = AxisType ,
- ?AutoTypeNumbers = AutoTypeNumbers ,
- ?AutoRange = AutoRange ,
- ?RangeMode = RangeMode ,
- ?Range = Range ,
- ?CategoryOrder = CategoryOrder ,
- ?CategoryArray = CategoryArray ,
- ?Angle = Angle ,
- ?Side = Side ,
- ?Title = Title ,
- ?HoverFormat = HoverFormat ,
- ?UIRevision = UIRevision ,
- ?Color = Color ,
- ?ShowLine = ShowLine ,
- ?LineColor = LineColor ,
- ?LineWidth = LineWidth ,
- ?ShowGrid = ShowGrid ,
- ?GridColor = GridColor ,
- ?GridWidth = GridWidth ,
- ?TickMode = TickMode ,
- ?NTicks = NTicks ,
- ?Tick0 = Tick0 ,
- ?DTick = DTick ,
- ?TickVals = TickVals ,
- ?TickText = TickText ,
- ?Ticks = Ticks ,
- ?TickLen = TickLen ,
- ?TickWidth = TickWidth ,
- ?TickColor = TickColor ,
- ?ShowTickLabels = ShowTickLabels ,
- ?ShowTickPrefix = ShowTickPrefix ,
- ?TickPrefix = TickPrefix ,
- ?ShowTickSuffix = ShowTickSuffix ,
- ?TickSuffix = TickSuffix ,
- ?ShowExponent = ShowExponent ,
- ?ExponentFormat = ExponentFormat ,
- ?MinExponent = MinExponent ,
- ?SeparateThousands = SeparateThousands ,
- ?TickFont = TickFont ,
- ?TickAngle = TickAngle ,
- ?TickFormat = TickFormat ,
- ?TickFormatStops = TickFormatStops ,
- ?Layer = Layer ,
- ?Calendar = Calendar
- )
-
- ///
- /// Creates a function that applies the given style parameters to a RadialAxis object
- ///
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets the angular axis type. If "linear", set `thetaunit` to determine the unit in which axis value are shown. If "category, use `period` to set the number of integer coordinates around polar axis.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Determines whether or not the range of this axis is computed in relation to the input data. See `rangemode` for more info. If `range` is provided, then `autorange` is set to "false".
- /// If "tozero"`, the range extends to 0, regardless of the input data If "nonnegative", the range is non-negative, regardless of the input data. If "normal", the range is computed in relation to the extrema of the input data (same behavior as for cartesian axes).
- /// Sets the range of this axis. If the axis `type` is "log", then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axis `type` is "date", it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axis `type` is "category", it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Sets the angle (in degrees) from which the radial axis is drawn. Note that by default, radial axis line on the theta=0 line corresponds to a line pointing right (like what mathematicians prefer). Defaults to the first `polar.sector` angle.
- /// Determines on which side of radial axis line the tick and tick labels appear.
- /// Sets the title of the Radial Axis.
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Controls persistence of user-driven changes in axis `rotation`. Defaults to `polar<N>.uirevision`.
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- /// Sets the calendar system to use for `range` and `tick0` if this is a date axis. This does not set the calendar for interpreting data on this axis, that's specified in the trace or via the global `layout.calendar`
- static member style
- (
- ?Visible : bool,
- ?AxisType : StyleParam.AxisType,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?AutoRange : StyleParam.AutoRange,
- ?RangeMode : StyleParam.RangeMode,
- ?Range : StyleParam.Range,
- ?CategoryOrder : StyleParam.CategoryOrder,
- ?CategoryArray : seq<#IConvertible>,
- ?Angle : float,
- ?Side : StyleParam.Direction,
- ?Title : Title,
- ?HoverFormat : string,
- ?UIRevision : #IConvertible,
- ?Color : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : int,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : int,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TickLen : int,
- ?TickWidth : int,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFont : Font,
- ?TickAngle : int,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?Layer : StyleParam.Layer,
- ?Calendar : StyleParam.Calendar
- ) =
- fun (radialAxis:RadialAxis) ->
-
- Visible |> DynObj.setValueOpt radialAxis "visible"
- AxisType |> DynObj.setValueOptBy radialAxis "type" StyleParam.AxisType.convert
- AutoTypeNumbers |> DynObj.setValueOptBy radialAxis "autotypenumbers" StyleParam.AutoTypeNumbers.convert
- AutoRange |> DynObj.setValueOptBy radialAxis "autorange" StyleParam.AutoRange.convert
- RangeMode |> DynObj.setValueOptBy radialAxis "rangemode" StyleParam.RangeMode.convert
- Range |> DynObj.setValueOptBy radialAxis "range" StyleParam.Range.convert
- CategoryOrder |> DynObj.setValueOptBy radialAxis "categoryorder" StyleParam.CategoryOrder.convert
- CategoryArray |> DynObj.setValueOpt radialAxis "categoryarray"
- Angle |> DynObj.setValueOpt radialAxis "angle"
- Side |> DynObj.setValueOptBy radialAxis "side" StyleParam.Direction.convert
- Title |> DynObj.setValueOpt radialAxis "title"
- HoverFormat |> DynObj.setValueOpt radialAxis "hoverformat"
- UIRevision |> DynObj.setValueOpt radialAxis "uirevision"
- Color |> DynObj.setValueOpt radialAxis "color"
- ShowLine |> DynObj.setValueOpt radialAxis "showline"
- LineColor |> DynObj.setValueOpt radialAxis "linecolor"
- LineWidth |> DynObj.setValueOpt radialAxis "linewidth"
- ShowGrid |> DynObj.setValueOpt radialAxis "showgrid"
- GridColor |> DynObj.setValueOpt radialAxis "gridcolor"
- GridWidth |> DynObj.setValueOpt radialAxis "gridwidth"
- TickMode |> DynObj.setValueOptBy radialAxis "tickmode" StyleParam.TickMode.convert
- NTicks |> DynObj.setValueOpt radialAxis "nticks"
- Tick0 |> DynObj.setValueOpt radialAxis "tick0"
- DTick |> DynObj.setValueOpt radialAxis "dtick"
- TickVals |> DynObj.setValueOpt radialAxis "TickVals"
- TickText |> DynObj.setValueOpt radialAxis "TickText"
- Ticks |> DynObj.setValueOptBy radialAxis "ticks" StyleParam.TickOptions.convert
- TickLen |> DynObj.setValueOpt radialAxis "ticklen"
- TickWidth |> DynObj.setValueOpt radialAxis "tickwidth"
- TickColor |> DynObj.setValueOpt radialAxis "tickcolor"
- ShowTickLabels |> DynObj.setValueOpt radialAxis "showticklabels"
- ShowTickPrefix |> DynObj.setValueOptBy radialAxis "showtickprefix" StyleParam.ShowTickOption.convert
- TickPrefix |> DynObj.setValueOpt radialAxis "tickprefix"
- ShowTickSuffix |> DynObj.setValueOptBy radialAxis "showticksuffix" StyleParam.ShowTickOption.convert
- TickSuffix |> DynObj.setValueOpt radialAxis "ticksuffix"
- ShowExponent |> DynObj.setValueOptBy radialAxis "showexponent" StyleParam.ShowExponent.convert
- ExponentFormat |> DynObj.setValueOptBy radialAxis "exponentformat" StyleParam.ExponentFormat.convert
- MinExponent |> DynObj.setValueOpt radialAxis "minexponent"
- SeparateThousands |> DynObj.setValueOpt radialAxis "separatethousands"
- TickFont |> DynObj.setValueOpt radialAxis "tickfont"
- TickAngle |> DynObj.setValueOpt radialAxis "tickangle"
- TickFormat |> DynObj.setValueOpt radialAxis "TickFormat"
- TickFormatStops |> DynObj.setValueOpt radialAxis "tickformatstops"
- Layer |> DynObj.setValueOptBy radialAxis "layer" StyleParam.Layer.convert
- Calendar |> DynObj.setValueOptBy radialAxis "calendar" StyleParam.Calendar.convert
-
- radialAxis
-
- /// Angular axes can be used as a scale for the angular coordinates in polar plots.
- type AngularAxis () =
- inherit DynamicObj ()
-
- ///
- /// Initialize an AngularAxis object that can be used as a angular scale for polar coordinates.
- ///
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets the angular axis type. If "linear", set `thetaunit` to determine the unit in which axis value are shown. If "category, use `period` to set the number of integer coordinates around polar axis.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Sets the format unit of the formatted "theta" values. Has an effect only when `angularaxis.type` is "linear".
- /// Set the angular period. Has an effect only when `angularaxis.type` is "category".
- /// Sets the direction corresponding to positive angles.
- /// Sets that start position (in degrees) of the angular axis By default, polar subplots with `direction` set to "counterclockwise" get a `rotation` of "0" which corresponds to due East (like what mathematicians prefer). In turn, polar with `direction` set to "clockwise" get a rotation of "90" which corresponds to due North (like on a compass),
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Controls persistence of user-driven changes in axis `rotation`. Defaults to `polar<N>.uirevision`.
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- static member init
- (
- ?Visible : bool,
- ?AxisType : StyleParam.AxisType,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?CategoryOrder : StyleParam.CategoryOrder,
- ?CategoryArray : seq<#IConvertible>,
- ?ThetaUnit : StyleParam.AngularUnit,
- ?Period : float,
- ?Direction : StyleParam.Direction,
- ?Rotation : int,
- ?HoverFormat : string,
- ?UIRevision : #IConvertible,
- ?Color : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : int,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : int,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TickLen : int,
- ?TickWidth : int,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFont : Font,
- ?TickAngle : int,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?Layer : StyleParam.Layer
- ) =
- AngularAxis()
- |> AngularAxis.style
- (
- ?Visible = Visible ,
- ?AxisType = AxisType ,
- ?AutoTypeNumbers = AutoTypeNumbers ,
- ?CategoryOrder = CategoryOrder ,
- ?CategoryArray = CategoryArray ,
- ?ThetaUnit = ThetaUnit ,
- ?Period = Period ,
- ?Direction = Direction ,
- ?Rotation = Rotation ,
- ?HoverFormat = HoverFormat ,
- ?UIRevision = UIRevision ,
- ?Color = Color ,
- ?ShowLine = ShowLine ,
- ?LineColor = LineColor ,
- ?LineWidth = LineWidth ,
- ?ShowGrid = ShowGrid ,
- ?GridColor = GridColor ,
- ?GridWidth = GridWidth ,
- ?TickMode = TickMode ,
- ?NTicks = NTicks ,
- ?Tick0 = Tick0 ,
- ?DTick = DTick ,
- ?TickVals = TickVals ,
- ?TickText = TickText ,
- ?Ticks = Ticks ,
- ?TickLen = TickLen ,
- ?TickWidth = TickWidth ,
- ?TickColor = TickColor ,
- ?ShowTickLabels = ShowTickLabels ,
- ?ShowTickPrefix = ShowTickPrefix ,
- ?TickPrefix = TickPrefix ,
- ?ShowTickSuffix = ShowTickSuffix ,
- ?TickSuffix = TickSuffix ,
- ?ShowExponent = ShowExponent ,
- ?ExponentFormat = ExponentFormat ,
- ?MinExponent = MinExponent ,
- ?SeparateThousands = SeparateThousands,
- ?TickFont = TickFont ,
- ?TickAngle = TickAngle ,
- ?TickFormat = TickFormat ,
- ?TickFormatStops = TickFormatStops ,
- ?Layer = Layer
- )
-
- ///
- /// Creates a function that applies the given style parameters to a AngularAxis object
- ///
- /// A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false
- /// Sets the angular axis type. If "linear", set `thetaunit` to determine the unit in which axis value are shown. If "category, use `period` to set the number of integer coordinates around polar axis.
- /// Using "strict" a numeric string in trace data is not converted to a number. Using "convert types" a numeric string in trace data may be treated as a number during automatic axis `type` detection. Defaults to layout.autotypenumbers.
- /// Specifies the ordering logic for the case of categorical variables. By default, plotly uses "trace", which specifies the order that is present in the data supplied. Set `categoryorder` to "category ascending" or "category descending" if order should be determined by the alphanumerical order of the category names. Set `categoryorder` to "array" to derive the ordering from the attribute `categoryarray`. If a category is not found in the `categoryarray` array, the sorting behavior for that attribute will be identical to the "trace" mode. The unspecified categories will follow the categories in `categoryarray`. Set `categoryorder` to "total ascending" or "total descending" if order should be determined by the numerical order of the values. Similarly, the order can be determined by the min, max, sum, mean or median of all the values.
- /// Sets the order in which categories on this axis appear. Only has an effect if `categoryorder` is set to "array". Used with `categoryorder`.
- /// Sets the format unit of the formatted "theta" values. Has an effect only when `angularaxis.type` is "linear".
- /// Set the angular period. Has an effect only when `angularaxis.type` is "category".
- /// Sets the direction corresponding to positive angles.
- /// Sets that start position (in degrees) of the angular axis By default, polar subplots with `direction` set to "counterclockwise" get a `rotation` of "0" which corresponds to due East (like what mathematicians prefer). In turn, polar with `direction` set to "clockwise" get a rotation of "90" which corresponds to due North (like on a compass),
- /// Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Controls persistence of user-driven changes in axis `rotation`. Defaults to `polar<N>.uirevision`.
- /// Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- /// Determines whether or not a line bounding this axis is drawn.
- /// Sets the axis line color.
- /// Sets the width (in px) of the axis line.
- /// Determines whether or not grid lines are drawn. If "true", the grid lines are drawn at every tick mark.
- /// Sets the color of the grid lines.
- /// Sets the width (in px) of the grid lines.
- /// Sets the tick mode for this axis. If "auto", the number of ticks is set via `nticks`. If "linear", the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `TickVals` and the tick text is `TickText`. ("array" is the default value if `TickVals` is provided).
- /// Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to "auto".
- /// Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
- /// Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to "log" and "date" axes. If the axis `type` is "log", then ticks are set every 10^(n"dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. "log" has several special values; "L<f>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = "L0.5" will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use "D1" (all digits) or "D2" (only 2 and 5). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
- /// Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `TickText`.
- /// Sets the text displayed at the ticks position via `TickVals`. Only has an effect if `tickmode` is set to "array". Used with `TickVals`.
- /// Determines whether ticks are drawn or not. If "", this axis' ticks are not drawn. If "outside" ("inside"), this axis' are drawn outside (inside) the axis lines.
- /// Sets the tick length (in px).
- /// Sets the tick width (in px).
- /// Sets the tick color.
- /// Determines whether or not the tick labels are drawn.
- /// If "all", all tick labels are displayed with a prefix. If "first", only the first tick is displayed with a prefix. If "last", only the last tick is displayed with a suffix. If "none", tick prefixes are hidden.
- /// Sets a tick label prefix.
- /// Same as `showtickprefix` but for tick suffixes.
- /// Sets a tick label suffix.
- /// If "all", all exponents are shown besides their significands. If "first", only the exponent of the first tick is shown. If "last", only the exponent of the last tick is shown. If "none", no exponents appear.
- /// Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If "none", it appears as 1,000,000,000. If "e", 1e+9. If "E", 1E+9. If "power", 1x10^9 (with 9 in a super script). If "SI", 1G. If "B", 1B.
- /// Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `TickFormat` is "SI" or "B".
- /// If "true", even 4-digit integers are separated
- /// Sets the tick font.
- /// Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
- /// Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format. And for dates see: https://github.com/d3/d3-time-format#locale_format. We add two items to d3's date formatter: "%h" for half of the year as a decimal number as well as "%{n}f" for fractional seconds with n digits. For example, "2016-10-13 09:15:23.456" with TickFormat "%H~%M~%S.%2f" would display "09~15~23.46"
- /// Set rules for customizing TickFormat on different zoom levels
- /// Sets the layer on which this axis is displayed. If "above traces", this axis is displayed above all the subplot's traces If "below traces", this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to "false" to show markers and/or text nodes above this axis.
- static member style
- (
- ?Visible : bool,
- ?AxisType : StyleParam.AxisType,
- ?AutoTypeNumbers : StyleParam.AutoTypeNumbers,
- ?CategoryOrder : StyleParam.CategoryOrder,
- ?CategoryArray : seq<#IConvertible>,
- ?ThetaUnit : StyleParam.AngularUnit,
- ?Period : float,
- ?Direction : StyleParam.Direction,
- ?Rotation : int,
- ?HoverFormat : string,
- ?UIRevision : #IConvertible,
- ?Color : string,
- ?ShowLine : bool,
- ?LineColor : string,
- ?LineWidth : int,
- ?ShowGrid : bool,
- ?GridColor : string,
- ?GridWidth : int,
- ?TickMode : StyleParam.TickMode,
- ?NTicks : int,
- ?Tick0 : #IConvertible,
- ?DTick : #IConvertible,
- ?TickVals : seq<#IConvertible>,
- ?TickText : seq<#IConvertible>,
- ?Ticks : StyleParam.TickOptions,
- ?TickLen : int,
- ?TickWidth : int,
- ?TickColor : string,
- ?ShowTickLabels : bool,
- ?ShowTickPrefix : StyleParam.ShowTickOption,
- ?TickPrefix : string,
- ?ShowTickSuffix : StyleParam.ShowTickOption,
- ?TickSuffix : string,
- ?ShowExponent : StyleParam.ShowExponent,
- ?ExponentFormat : StyleParam.ExponentFormat,
- ?MinExponent : float,
- ?SeparateThousands : bool,
- ?TickFont : Font,
- ?TickAngle : int,
- ?TickFormat : string,
- ?TickFormatStops : seq,
- ?Layer : StyleParam.Layer
- ) =
- fun (angularAxis: AngularAxis) ->
-
- Visible |> DynObj.setValueOpt angularAxis "visible"
- AxisType |> DynObj.setValueOptBy angularAxis "type" StyleParam.AxisType.convert
- AutoTypeNumbers |> DynObj.setValueOptBy angularAxis "autotypenumbers" StyleParam.AutoTypeNumbers.convert
- CategoryOrder |> DynObj.setValueOptBy angularAxis "categoryorder" StyleParam.CategoryOrder.convert
- CategoryArray |> DynObj.setValueOpt angularAxis "categoryarray"
- ThetaUnit |> DynObj.setValueOpt angularAxis "thetaunit"
- Period |> DynObj.setValueOpt angularAxis "Period"
- Direction |> DynObj.setValueOpt angularAxis "Direction"
- Rotation |> DynObj.setValueOpt angularAxis "Rotation"
- HoverFormat |> DynObj.setValueOpt angularAxis "hoverformat"
- UIRevision |> DynObj.setValueOpt angularAxis "uirevision"
- Color |> DynObj.setValueOpt angularAxis "color"
- ShowLine |> DynObj.setValueOpt angularAxis "showline"
- LineColor |> DynObj.setValueOpt angularAxis "linecolor"
- LineWidth |> DynObj.setValueOpt angularAxis "linewidth"
- ShowGrid |> DynObj.setValueOpt angularAxis "showgrid"
- GridColor |> DynObj.setValueOpt angularAxis "gridcolor"
- GridWidth |> DynObj.setValueOpt angularAxis "gridwidth"
- TickMode |> DynObj.setValueOptBy angularAxis "tickmode" StyleParam.TickMode.convert
- NTicks |> DynObj.setValueOpt angularAxis "nticks"
- Tick0 |> DynObj.setValueOpt angularAxis "tick0"
- DTick |> DynObj.setValueOpt angularAxis "dtick"
- TickVals |> DynObj.setValueOpt angularAxis "TickVals"
- TickText |> DynObj.setValueOpt angularAxis "TickText"
- Ticks |> DynObj.setValueOptBy angularAxis "ticks" StyleParam.TickOptions.convert
- TickLen |> DynObj.setValueOpt angularAxis "ticklen"
- TickWidth |> DynObj.setValueOpt angularAxis "tickwidth"
- TickColor |> DynObj.setValueOpt angularAxis "tickcolor"
- ShowTickLabels |> DynObj.setValueOpt angularAxis "showticklabels"
- ShowTickPrefix |> DynObj.setValueOptBy angularAxis "showtickprefix" StyleParam.ShowTickOption.convert
- TickPrefix |> DynObj.setValueOpt angularAxis "tickprefix"
- ShowTickSuffix |> DynObj.setValueOptBy angularAxis "showticksuffix" StyleParam.ShowTickOption.convert
- TickSuffix |> DynObj.setValueOpt angularAxis "ticksuffix"
- ShowExponent |> DynObj.setValueOptBy angularAxis "showexponent" StyleParam.ShowExponent.convert
- ExponentFormat |> DynObj.setValueOptBy angularAxis "exponentformat" StyleParam.ExponentFormat.convert
- MinExponent |> DynObj.setValueOpt angularAxis "minexponent"
- SeparateThousands |> DynObj.setValueOpt angularAxis "separatethousands"
- TickFont |> DynObj.setValueOpt angularAxis "tickfont"
- TickAngle |> DynObj.setValueOpt angularAxis "tickangle"
- TickFormat |> DynObj.setValueOpt angularAxis "TickFormat"
- TickFormatStops |> DynObj.setValueOpt angularAxis "tickformatstops"
- Layer |> DynObj.setValueOptBy angularAxis "layer" StyleParam.Layer.convert
-
- angularAxis
-
- type ColorAxis() =
- inherit DynamicObj()
-
- ///
- /// Initializes a ColorAxis object
- ///
- /// Determines whether the colorscale is a default palette (`autocolorscale: true`) or the palette determined by `colorscale`. In case `colorscale` is unspecified or `autocolorscale` is true, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
- /// Determines whether or not the color domain is computed with respect to the input data (here corresponding trace color array(s)) or the bounds set in `cmin` and `cmax` Defaults to `false` when `cmin` and `cmax` are set by the user.
- /// Sets the lower bound of the color domain. Value should have the same units as corresponding trace color array(s) and if set, `cmax` must be set as well.
- /// Sets the mid-point of the color domain by scaling `cmin` and/or `cmax` to be equidistant to this point. Value should have the same units as corresponding trace color array(s). Has no effect when `cauto` is `false`.
- /// Sets the upper bound of the color domain. Value should have the same units as corresponding trace color array(s) and if set, `cmin` must be set as well.
- /// Sets the colorbar associated with this color axis.
- /// Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example, `[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]`. To control the bounds of the colorscale in color space, use`cmin` and `cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Blackbody,Bluered,Blues,Cividis,Earth,Electric,Greens,Greys,Hot,Jet,Picnic,Portland,Rainbow,RdBu,Reds,Viridis,YlGnBu,YlOrRd.
- /// Reverses the color mapping if true. If true, `cmin` will correspond to the last color in the array and `cmax` will correspond to the first color.
- /// Determines whether or not a colorbar is displayed for this trace.
- static member init
- (
- ?AutoColorScale : bool,
- ?CAuto : float,
- ?CMin : float,
- ?CMid : float,
- ?CMax : float,
- ?ColorBar : ColorBar,
- ?ColorScale : StyleParam.Colorscale,
- ?ShowScale : bool,
- ?ReverseScale : bool
- ) =
-
- ColorAxis()
- |> ColorAxis.style
- (
- ?AutoColorScale = AutoColorScale,
- ?CAuto = CAuto ,
- ?CMin = CMin ,
- ?CMid = CMid ,
- ?CMax = CMax ,
- ?ColorBar = ColorBar ,
- ?ColorScale = ColorScale ,
- ?ShowScale = ShowScale ,
- ?ReverseScale = ReverseScale
- )
- ///
- /// Creates a function that applies the given style parameters to a ColorAxis object
- ///
- /// Determines whether the colorscale is a default palette (`autocolorscale: true`) or the palette determined by `colorscale`. In case `colorscale` is unspecified or `autocolorscale` is true, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
- /// Determines whether or not the color domain is computed with respect to the input data (here corresponding trace color array(s)) or the bounds set in `cmin` and `cmax` Defaults to `false` when `cmin` and `cmax` are set by the user.
- /// Sets the lower bound of the color domain. Value should have the same units as corresponding trace color array(s) and if set, `cmax` must be set as well.
- /// Sets the mid-point of the color domain by scaling `cmin` and/or `cmax` to be equidistant to this point. Value should have the same units as corresponding trace color array(s). Has no effect when `cauto` is `false`.
- /// Sets the upper bound of the color domain. Value should have the same units as corresponding trace color array(s) and if set, `cmin` must be set as well.
- /// Sets the colorbar associated with this color axis.
- /// Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example, `[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]`. To control the bounds of the colorscale in color space, use`cmin` and `cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Blackbody,Bluered,Blues,Cividis,Earth,Electric,Greens,Greys,Hot,Jet,Picnic,Portland,Rainbow,RdBu,Reds,Viridis,YlGnBu,YlOrRd.
- /// Reverses the color mapping if true. If true, `cmin` will correspond to the last color in the array and `cmax` will correspond to the first color.
- /// Determines whether or not a colorbar is displayed for this trace.
- static member style
- (
- ?AutoColorScale : bool,
- ?CAuto : float,
- ?CMin : float,
- ?CMid : float,
- ?CMax : float,
- ?ColorBar : ColorBar,
- ?ColorScale : StyleParam.Colorscale,
- ?ShowScale : bool,
- ?ReverseScale : bool
- ) =
- fun (ca:ColorAxis) ->
-
- AutoColorScale |> DynObj.setValueOpt ca "autocolorscale"
- CAuto |> DynObj.setValueOpt ca "cauto"
- CMin |> DynObj.setValueOpt ca "cmin"
- CMid |> DynObj.setValueOpt ca "cmid"
- CMax |> DynObj.setValueOpt ca "cmax"
- ColorBar |> DynObj.setValueOpt ca "colorbar"
- ColorScale |> DynObj.setValueOpt ca "colorscale"
- ShowScale |> DynObj.setValueOpt ca "showscale"
- ReverseScale |> DynObj.setValueOpt ca "reversescale"
-
- ca
\ No newline at end of file
diff --git a/src/Plotly.NET/GenericChartExtensions.fs b/src/Plotly.NET/CSharpLayer/GenericChartExtensions.fs
similarity index 93%
rename from src/Plotly.NET/GenericChartExtensions.fs
rename to src/Plotly.NET/CSharpLayer/GenericChartExtensions.fs
index 690250235..227d19391 100644
--- a/src/Plotly.NET/GenericChartExtensions.fs
+++ b/src/Plotly.NET/CSharpLayer/GenericChartExtensions.fs
@@ -1,5 +1,7 @@
namespace Plotly.NET
+open Plotly.NET.LayoutObjects
+open Plotly.NET.TraceObjects
open System
open System.IO
@@ -39,7 +41,7 @@ module GenericChartExtensions =
[]
[]
member this.WithMarker(marker:Marker) =
- this |> mapTrace (Trace.TraceStyle.SetMarker(marker))
+ this |> Chart.withMarker marker
/// Apply styling to the Marker(s) of the chart.
[]
@@ -51,17 +53,19 @@ module GenericChartExtensions =
[] ?Symbol,
[] ?Opacity
) =
- let marker =
- Marker.init (
- ?Size=Size,?Color=Color,?Symbol=Symbol,?Opacity=Opacity
- )
- this |> Chart.withMarker(marker)
+ this
+ |> Chart.withMarkerStyle(
+ ?Size=Size,
+ ?Color=Color,
+ ?Symbol=Symbol,
+ ?Opacity=Opacity
+ )
/// Apply styling to the Line(s) of the chart as Object.
[]
[]
member this.WithLine(line:Line) =
- this |> mapTrace (Trace.TraceStyle.SetLine(line))
+ this |> Chart.withLine line
/// Apply styling to the Line(s) of the chart.
[]
@@ -75,17 +79,21 @@ module GenericChartExtensions =
[] ?Smoothing,
[] ?Colorscale
) =
- let line =
- Line.init (
- ?Width=Width,?Color=Color,?Shape=Shape,?Dash=Dash,?Smoothing=Smoothing,?Colorscale=Colorscale)
-
- this |> Chart.withLine(line)
+ this
+ |> Chart.withLineStyle(
+ ?Width=Width,
+ ?Color=Color,
+ ?Shape=Shape,
+ ?Dash=Dash,
+ ?Smoothing=Smoothing,
+ ?Colorscale=Colorscale
+ )
/// Apply styling to the xError(s) of the chart as Object
[]
[]
member this.WithXError(xError:Error) =
- this |> mapTrace (Trace.TraceStyle.SetErrorX(xError))
+ this |> Chart.withXError xError
/// Apply styling to the xError(s) of the chart as Object
[]
@@ -106,7 +114,7 @@ module GenericChartExtensions =
[]
[]
member this.WithYError(yError:Error) =
- this |> mapTrace (Trace.TraceStyle.SetErrorY(yError))
+ this |> mapTrace (TraceStyle.SetErrorY(yError))
/// Apply styling to the yError(s) of the chart as Object
[]
@@ -127,7 +135,7 @@ module GenericChartExtensions =
[]
[]
member this.WithZError(zError:Error) =
- this |> mapTrace (Trace.TraceStyle.SetErrorZ(zError))
+ this |> mapTrace (TraceStyle.SetErrorZ(zError))
/// Apply styling to the zError(s) of the chart as Object
@@ -152,7 +160,7 @@ module GenericChartExtensions =
// Sets x-Axis of 2d and 3d- Charts
[]
[]
- member this.WithXAxis(xAxis:Axis.LinearAxis,[] ?Id: StyleParam.SubPlotId) =
+ member this.WithXAxis(xAxis:LinearAxis,[] ?Id: StyleParam.SubPlotId) =
this |> Chart.withXAxis(xAxis, ?Id = Id)
// Sets x-Axis of 2d and 3d- Charts
@@ -171,7 +179,7 @@ module GenericChartExtensions =
[] ?Anchor) =
let range = if MinMax.IsSome then Some (StyleParam.Range.MinMax (MinMax.Value)) else None
let domain = if Domain.IsSome then Some (StyleParam.Range.MinMax (Domain.Value)) else None
- let xaxis = Axis.LinearAxis.init(Title=title,?Range=range,?ShowGrid=ShowGrid,?ShowLine=ShowLine,
+ let xaxis = LinearAxis.init(Title=title,?Range=range,?ShowGrid=ShowGrid,?ShowLine=ShowLine,
?Anchor=Anchor,?Side=Side,?Domain=domain,?Overlaying=Overlaying,?Position=Position,?ZeroLine=ZeroLine)
this |> Chart.withXAxis(xaxis,?Id=Id)
@@ -180,13 +188,13 @@ module GenericChartExtensions =
[]
member this.WithXAxisRangeSlider(rangeSlider:RangeSlider,
[] ?Id) =
- let xaxis = Axis.LinearAxis.init(RangeSlider = rangeSlider)
+ let xaxis = LinearAxis.init(RangeSlider = rangeSlider)
this |> Chart.withXAxis(xaxis,?Id=Id)
// Sets y-Axis of 2d and 3d- Charts
[]
[]
- member this.WithYAxis(yAxis:Axis.LinearAxis,[] ?Id: StyleParam.SubPlotId) =
+ member this.WithYAxis(yAxis:LinearAxis,[] ?Id: StyleParam.SubPlotId) =
this |> Chart.withYAxis(yAxis, ?Id = Id)
// Sets y-Axis of 3d- Charts
@@ -205,7 +213,7 @@ module GenericChartExtensions =
[] ?Anchor) =
let range = if MinMax.IsSome then Some (StyleParam.Range.MinMax (MinMax.Value)) else None
let domain = if Domain.IsSome then Some (StyleParam.Range.MinMax (Domain.Value)) else None
- let yaxis = Axis.LinearAxis.init(Title=title,?Range=range,?ShowGrid=ShowGrid,
+ let yaxis = LinearAxis.init(Title=title,?Range=range,?ShowGrid=ShowGrid,
?ShowLine=ShowLine,?Anchor=Anchor,?Side=Side,?Domain=domain,?Overlaying=Overlaying,?Position=Position,?ZeroLine=ZeroLine)
this |> Chart.withYAxis(yaxis,?Id=Id)
@@ -213,7 +221,7 @@ module GenericChartExtensions =
// Sets z-Axis of 3d- Charts
[]
[]
- member this.WithZAxis(zAxis:Axis.LinearAxis, [] ?Id: StyleParam.SubPlotId) =
+ member this.WithZAxis(zAxis:LinearAxis, [] ?Id: StyleParam.SubPlotId) =
this |> Chart.withZAxis(zAxis, ?Id=Id)
@@ -229,7 +237,7 @@ module GenericChartExtensions =
[] ?Anchor) =
let range = if MinMax.IsSome then Some (StyleParam.Range.MinMax (MinMax.Value)) else None
let domain = if Domain.IsSome then Some (StyleParam.Range.MinMax (Domain.Value)) else None
- let zaxis = Axis.LinearAxis.init(Title=title,?Range=range,?ShowGrid=ShowGrid,?ShowLine=ShowLine,?Anchor=Anchor,?Domain=domain)
+ let zaxis = LinearAxis.init(Title=title,?Range=range,?ShowGrid=ShowGrid,?ShowLine=ShowLine,?Anchor=Anchor,?Domain=domain)
this |> Chart.withZAxis(zaxis)
[]
@@ -384,8 +392,8 @@ module GenericChartExtensions =
[]?FrameColor,
[]?FrameWidth : float,
[]?BgColor,
- []?LatAxis : Axis.LinearAxis,
- []?LonAxis : Axis.LinearAxis
+ []?LatAxis : LinearAxis,
+ []?LonAxis : LinearAxis
) =
this
|> Chart.withGeoStyle(
@@ -513,7 +521,7 @@ module GenericChartExtensions =
member this.WithLegend(showlegend) =
let layout =
Layout()
- |> Layout.style(Showlegend=showlegend)
+ |> Layout.style(ShowLegend=showlegend)
GenericChart.addLayout layout this
// Set the size of a Chart
@@ -633,17 +641,17 @@ module GenericChartExtensions =
/// Sets the angular axis of the polar object with the given id on the chart layout
[]
- member this.WithAngularAxis(angularAxis:Axis.AngularAxis, [] ?Id) =
+ member this.WithAngularAxis(angularAxis:AngularAxis, [] ?Id) =
this |> Chart.withAngularAxis(angularAxis,?Id=Id)
/// Sets the radial axis of the polar object with the given id on the chart layout
[]
- member this.WithRadialAxis(radialAxis:Axis.RadialAxis, [] ?Id) =
+ member this.WithRadialAxis(radialAxis:RadialAxis, [] ?Id) =
this |> Chart.withRadialAxis(radialAxis,?Id=Id)
/// Sets the color axis of the color axis with the given id on the chart layout
[]
- member this.WithColorAxis(colorAxis:Axis.ColorAxis, [] ?Id) =
+ member this.WithColorAxis(colorAxis:ColorAxis, [] ?Id) =
this |> Chart.withColorAxis(colorAxis,?Id=Id)
/// Sets the scene object with the given id on the chart layout
diff --git a/src/Plotly.NET/CandelstickExtension.fs b/src/Plotly.NET/CandelstickExtension.fs
deleted file mode 100644
index 0d2f85843..000000000
--- a/src/Plotly.NET/CandelstickExtension.fs
+++ /dev/null
@@ -1,50 +0,0 @@
-namespace Plotly.NET
-
-open DynamicObj
-open Trace
-open System
-open System.Runtime.InteropServices
-
-[]
-type Candle =
- {
- High : float
- Low : float
- Close : float
- Open : float
- }
- with
- static member Create(o,h,l,c) =
- {
- High = h
- Low = l
- Close = c
- Open = o
- }
-
-[]
-module CandelstickExtension =
-
- type Chart with
- []
- []
- static member Candelstick
- (
- data : (#IConvertible*Candle) seq,
- [] ?increasing : Line,
- [] ?decreasing : Line,
- [] ?line : Line
- ) =
- Trace.initCandlestick(
- TraceStyle.Candlestick(
- ``open`` = (data |> Seq.map (snd >> (fun x -> x.Open))) ,
- high = (data |> Seq.map (snd >> (fun x -> x.High))) ,
- low = (data |> Seq.map (snd >> (fun x -> x.Low))) ,
- close = (data |> Seq.map (snd >> (fun x -> x.Close))) ,
- x = (data |> Seq.map fst) ,
- ?Increasing = increasing ,
- ?Decreasing = decreasing ,
- ?Line = line
- )
- )
- |> GenericChart.ofTraceObject
diff --git a/src/Plotly.NET/Chart.fs b/src/Plotly.NET/Chart.fs
deleted file mode 100644
index 18d7f697f..000000000
--- a/src/Plotly.NET/Chart.fs
+++ /dev/null
@@ -1,4070 +0,0 @@
-namespace Plotly.NET
-
-open DynamicObj
-open System
-open System.IO
-//open FSharp.Care.Collections
-
-open GenericChart
-open Trace
-open Trace3d
-open StyleParam
-open System.Runtime.InteropServices
-
-// ###########
-// Copied from FSharp.Care.Collections to remove dependancies
-[]
-module Seq =
-
- /// Splits a sequence of pairs into two sequences
- let unzip (input:seq<_>) =
- let (lstA, lstB) =
- Seq.foldBack (fun (a,b) (accA, accB) ->
- a::accA, b::accB) input ([],[])
- (Seq.ofList lstA, Seq.ofList lstB)
-
- /// Splits a sequence of triples into three sequences
- let unzip3 (input:seq<_>) =
- let (lstA, lstB, lstC) =
- Seq.foldBack (fun (a,b,c) (accA, accB, accC) ->
- a::accA, b::accB, c::accC) input ([],[],[])
- (Seq.ofList lstA, Seq.ofList lstB, Seq.ofList lstC)
-
-
-/// Provides a set of static methods for creating charts.
-type Chart =
-
- static member private renderScatterTrace (useWebGL:bool) (style: Trace -> Trace) =
- if useWebGL then
- Trace.initScatterGL style
- |> GenericChart.ofTraceObject
- else
- Trace.initScatter style
- |> GenericChart.ofTraceObject
-
- static member private renderScatterPolarTrace (useWebGL:bool) (style: Trace -> Trace) =
- if useWebGL then
- Trace.initScatterPolarGL style
- |> GenericChart.ofTraceObject
- else
- Trace.initScatterPolar style
- |> GenericChart.ofTraceObject
-
- /// Creates a chart that is completely invisible when rendered. The Chart object however is NOT empty! Combining this chart with other charts will have unforseen consequences (it has for example invisible axes that can override other axes if used in Chart.Combine)
- static member Invisible () =
- let hiddenAxis() =
- Axis.LinearAxis.init(
- ShowGrid = false,
- ShowLine = false,
- ShowTickLabels = false,
- ZeroLine = false
- )
-
- let trace = Trace("scatter")
- trace.Remove("type") |> ignore
- GenericChart.ofTraceObject trace
- |> GenericChart.mapLayout ( fun l ->
- l
- |> Layout.AddLinearAxis(StyleParam.SubPlotId.XAxis 1,hiddenAxis())
- |> Layout.AddLinearAxis(StyleParam.SubPlotId.YAxis 1,hiddenAxis())
- )
-
-
- /// Creates a Scatter chart. Scatter charts are the basis of Point, Line, and Bubble Charts in Plotly, and can be customized as such. We also provide abstractions for those: Chart.Line, Chart.Point, Chart.Bubble
- /// Sets the x coordinates of the plotted data.
- /// Sets the y coordinates of the plotted data.
- /// Determines the drawing mode for this scatter trace.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Sets the Line Dash style
- /// Sets the Line width
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Scatter(x, y, mode,
- [] ?Name ,
- [] ?Showlegend ,
- [] ?MarkerSymbol ,
- [] ?Color ,
- [] ?Opacity ,
- [] ?Labels ,
- [] ?TextPosition ,
- [] ?TextFont ,
- [] ?Dash ,
- [] ?Width : float ,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
-
- let style =
- TraceStyle.Scatter(
- X = x ,
- Y = y ,
- Mode = mode ,
- ?StackGroup = StackGroup ,
- ?Orientation= Orientation ,
- ?GroupNorm = GroupNorm
- )
- >> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend,?Opacity=Opacity)
- >> TraceStyle.Line(?Color=Color,?Dash=Dash,?Width=Width)
- >> TraceStyle.Marker(?Color=Color,?Symbol=MarkerSymbol)
- >> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let useWebGL = defaultArg UseWebGL false
-
- Chart.renderScatterTrace useWebGL style
-
-
- /// Creates a Scatter chart. Scatter charts are the basis of Point, Line, and Bubble Charts in Plotly, and can be customized as such. We also provide abstractions for those: Chart.Line, Chart.Point, Chart.Bubble
- /// Sets the x,y coordinates of the plotted data.
- /// Determines the drawing mode for this scatter trace.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Sets the Line Dash style
- /// Sets the Line width
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Scatter(xy,mode,
- [] ?Name ,
- [] ?Showlegend ,
- [] ?MarkerSymbol ,
- [] ?Color ,
- [] ?Opacity ,
- [] ?Labels ,
- [] ?TextPosition ,
- [] ?TextFont ,
- [] ?Dash ,
- [] ?Width ,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool) =
- let x,y = Seq.unzip xy
- Chart.Scatter(x, y, mode,
- ?Name = Name ,
- ?Showlegend = Showlegend ,
- ?MarkerSymbol = MarkerSymbol ,
- ?Color = Color ,
- ?Opacity = Opacity ,
- ?Labels = Labels ,
- ?TextPosition = TextPosition ,
- ?TextFont = TextFont ,
- ?Dash = Dash ,
- ?Width = Width ,
- ?StackGroup = StackGroup ,
- ?Orientation = Orientation ,
- ?GroupNorm = GroupNorm ,
- ?UseWebGL = UseWebGL
- )
-
-
-
- /// Creates a Point chart, which uses Points in a 2D space to visualize data.
- /// Sets the x coordinates of the plotted data.
- /// Sets the y coordinates of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Point(x, y,
- [] ?Name,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- // if text position or font is set, then show labels (not only when hovering)
- let changeMode = StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
- let useWebGL = defaultArg UseWebGL false
-
- let style =
- TraceStyle.Scatter(
- X = x,
- Y = y,
- Mode = changeMode StyleParam.Mode.Markers,
- ?StackGroup = StackGroup,
- ?Orientation= Orientation,
- ?GroupNorm = GroupNorm)
- >> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend,?Opacity=Opacity)
- >> TraceStyle.Marker(?Color=Color,?Symbol=MarkerSymbol)
- >> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- Chart.renderScatterTrace useWebGL style
-
- /// Creates a Point chart, which uses Points in a 2D space to visualize data.
- /// Sets the x,y coordinates of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Point(xy,
- [] ?Name,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- let x,y = Seq.unzip xy
- Chart.Point(x, y,
- ?Name = Name,
- ?Showlegend = Showlegend,
- ?MarkerSymbol = MarkerSymbol,
- ?Color = Color,
- ?Opacity = Opacity,
- ?Labels = Labels,
- ?TextPosition = TextPosition,
- ?TextFont = TextFont,
- ?StackGroup = StackGroup,
- ?Orientation = Orientation,
- ?GroupNorm = GroupNorm,
- ?UseWebGL = UseWebGL
- )
-
-
- /// Creates a Line chart, which uses a Line plotted between the given datums in a 2D space to visualize typically an evolution of Y depending on X.
- /// Sets the x coordinates of the plotted data.
- /// Sets the y coordinates of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Wether to show markers for the individual data points
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Sets the Line Dash style
- /// Sets the Line width
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Line(x, y,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?Dash,
- [] ?Width,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- // if text position or font is set than show labels (not only when hovering)
- let changeMode =
- let isShowMarker =
- match ShowMarkers with
- | Some isShow -> isShow
- | Option.None -> false
- StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
- >> StyleParam.ModeUtils.showMarker (isShowMarker)
-
-
- let style =
- TraceStyle.Scatter(
- X = x,
- Y = y,
- Mode = changeMode StyleParam.Mode.Lines,
- ?StackGroup = StackGroup,
- ?Orientation= Orientation,
- ?GroupNorm = GroupNorm)
- >> TraceStyle.Line(?Color=Color,?Dash=Dash,?Width=Width)
- >> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend,?Opacity=Opacity)
- >> TraceStyle.Marker(?Color=Color,?Symbol=MarkerSymbol)
- >> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let useWebGL = defaultArg UseWebGL false
-
- Chart.renderScatterTrace useWebGL style
-
-
- /// Creates a Line chart, which uses a Line plotted between the given datums in a 2D space to visualize typically an evolution of Y depending on X.
- /// Sets the x,y coordinates of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Wether to show markers for the individual data points
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Sets the Line Dash style
- /// Sets the Line width
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Line(xy,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?Dash,
- [] ?Width,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- let x,y = Seq.unzip xy
- Chart.Line(
- x, y,
- ?Name = Name,
- ?ShowMarkers = ShowMarkers,
- ?Showlegend = Showlegend,
- ?MarkerSymbol = MarkerSymbol,
- ?Color = Color,
- ?Opacity = Opacity,
- ?Labels = Labels,
- ?TextPosition = TextPosition,
- ?TextFont = TextFont,
- ?Dash = Dash,
- ?Width = Width,
- ?StackGroup = StackGroup,
- ?Orientation = Orientation,
- ?GroupNorm = GroupNorm,
- ?UseWebGL = UseWebGL
- )
-
-
- /// Creates a Spline chart. A spline chart is a line chart in which data points are connected by smoothed curves: this modification is aimed to improve the design of a chart.
- /// Very similar to Line Plots, spline charts are typically used to visualize an evolution of Y depending on X.
- /// Sets the x coordinates of the plotted data.
- /// Sets the y coordinates of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Wether to show markers for the individual data points
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Sets the Line Dash style
- /// Sets the Line width
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// : Sets the amount of smoothing. "0" corresponds to no smoothing (equivalent to a "linear" shape). Use values between 0. and 1.3
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Spline(x, y,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?Dash,
- [] ?Width,
- [] ?Smoothing: float,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
-
- let changeMode =
- let isShowMarker =
- match ShowMarkers with
- | Some isShow -> isShow
- | Option.None -> false
- StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
- >> StyleParam.ModeUtils.showMarker (isShowMarker)
-
- let style =
- TraceStyle.Scatter(
- X = x,
- Y = y,
- Mode=changeMode StyleParam.Mode.Lines,
- ?StackGroup = StackGroup,
- ?Orientation= Orientation,
- ?GroupNorm = GroupNorm)
- >> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend,?Opacity=Opacity)
- >> TraceStyle.Line(?Color=Color,?Dash=Dash,?Width=Width, Shape=StyleParam.Shape.Spline, ?Smoothing=Smoothing)
- >> TraceStyle.Marker(?Color=Color,?Symbol=MarkerSymbol)
- >> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let useWebGL = defaultArg UseWebGL false
- Chart.renderScatterTrace useWebGL style
-
-
- /// Creates a Spline chart. A spline chart is a line chart in which data points are connected by smoothed curves: this modification is aimed to improve the design of a chart.
- /// Very similar to Line Plots, spline charts are typically used to visualize an evolution of Y depending on X.
- /// Sets the x,y coordinates of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Wether to show markers for the individual data points
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Sets the Line Dash style
- /// Sets the Line width
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// : Sets the amount of smoothing. "0" corresponds to no smoothing (equivalent to a "linear" shape). Use values between 0. and 1.3
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Spline(xy,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?Dash,
- [] ?Width,
- [] ?Smoothing,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- let x,y = Seq.unzip xy
- Chart.Spline(x, y,
- ?Name = Name,
- ?ShowMarkers = ShowMarkers,
- ?Showlegend = Showlegend,
- ?MarkerSymbol = MarkerSymbol,
- ?Color = Color,
- ?Opacity = Opacity,
- ?Labels = Labels,
- ?TextPosition = TextPosition,
- ?TextFont = TextFont,
- ?Dash = Dash,
- ?Width = Width,
- ?Smoothing = Smoothing,
- ?StackGroup = StackGroup,
- ?Orientation = Orientation,
- ?GroupNorm = GroupNorm,
- ?UseWebGL = UseWebGL
- )
-
-
- /// Creates a bubble chart. A bubble chart is a variation of the Point chart, where the data points get an additional scale by being rendered as bubbles of different sizes.
- /// Sets the x coordinates of the plotted data.
- /// Sets the y coordinates of the plotted data.
- /// Sets the bubble size of the plotted data
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Bubble(x, y,sizes:seq<#IConvertible>,
- [] ?Name,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- // if text position or font is set than show labels (not only when hovering)
- let changeMode = StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
-
- let style =
- TraceStyle.Scatter(
- X = x,
- Y = y,
- Mode=changeMode StyleParam.Mode.Markers,
- ?StackGroup = StackGroup,
- ?Orientation= Orientation,
- ?GroupNorm = GroupNorm)
- >> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend,?Opacity=Opacity)
- >> TraceStyle.Marker(?Color=Color,?Symbol=MarkerSymbol, MultiSizes=sizes)
- >> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let useWebGL = defaultArg UseWebGL false
- Chart.renderScatterTrace useWebGL style
-
- /// Creates a bubble chart. A bubble chart is a variation of the Point chart, where the data points get an additional scale by being rendered as bubbles of different sizes.
- /// Sets the x coordinates, y coordinates, and bubble sizes of the plotted data.
- /// Sets the trace name. The trace name appear as the legend item and on hover
- /// Determines whether or not an item corresponding to this trace is shown in the legend.
- /// Sets the type of symbol that datums are displayed as
- /// Sets Line/Marker Color
- /// Sets the Opacity of the trace
- /// Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
- /// Sets the positions of the `text` elements with respects to the (x,y) coordinates.
- /// Sets the text font of this trace
- /// Set several traces (on the same subplot) to the same stackgroup in order to add their y values (or their x values if `Orientation` is Horizontal). Stacking also turns `fill` on by default and sets the default `mode` to "lines" irrespective of point count. ou can only stack on a numeric (linear or log) axis. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order
- /// Sets the stacking direction. Only relevant when `stackgroup` is used, and only the first `orientation` found in the `stackgroup` will be used.
- /// Sets the normalization for the sum of this `stackgroup. Only relevant when `stackgroup` is used, and only the first `groupnorm` found in the `stackgroup` will be used
- /// If true, plotly.js will use the WebGL engine to render this chart. use this when you want to render many objects at once.
- static member Bubble(xysizes,[] ?Name,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?StackGroup ,
- [] ?Orientation ,
- [] ?GroupNorm ,
- []?UseWebGL : bool
- ) =
- let x,y,sizes = Seq.unzip3 xysizes
- Chart.Bubble(
- x, y,sizes,
- ?Name = Name,
- ?Showlegend = Showlegend,
- ?MarkerSymbol = MarkerSymbol,
- ?Color = Color,
- ?Opacity = Opacity,
- ?Labels = Labels,
- ?TextPosition = TextPosition,
- ?TextFont = TextFont,
- ?StackGroup = StackGroup,
- ?Orientation = Orientation,
- ?GroupNorm = GroupNorm,
- ?UseWebGL = UseWebGL
- )
-
-
- /// Displays a range of data by plotting two Y values per data point, with each Y value being drawn as a line
- []
- static member Range(x, y, upper, lower,?Name,?ShowMarkers,?Showlegend,?Color,?RangeColor,?Labels,?TextPosition,?TextFont) =
- // if text position or font is set than show labels (not only when hovering)
- let changeMode =
- let isShowMarker =
- match ShowMarkers with
- | Some isShow -> isShow
- | Option.None -> false
- StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
- >> StyleParam.ModeUtils.showMarker (isShowMarker)
-
-
- let trace =
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = y, Mode=changeMode StyleParam.Mode.Markers, ?Fillcolor=Color) )
- |> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend)
- |> TraceStyle.Line(?Color=Color)
- |> TraceStyle.Marker(?Color=Color)
- |> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let lower =
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = lower, Mode=StyleParam.Mode.Lines, ?Fillcolor=RangeColor) )
- |> TraceStyle.TraceInfo(Showlegend=false)
- |> TraceStyle.Line(Width=0.)
- |> TraceStyle.Marker(Color=if RangeColor.IsSome then RangeColor.Value else "rgba(0,0,,0.5)")
-
- let upper =
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = upper, Mode=StyleParam.Mode.Lines, ?Fillcolor=RangeColor, Fill=StyleParam.Fill.ToNext_y) )
- |> TraceStyle.TraceInfo(Showlegend=false)
- |> TraceStyle.Line(Width=0.)
- |> TraceStyle.Marker(Color=if RangeColor.IsSome then RangeColor.Value else "rgba(0,0,,0.5)")
-
- GenericChart.MultiChart ([lower;upper;trace],Layout(),Config(), DisplayOptions())
-
- []
- /// Displays a range of data by plotting two Y values per data point, with each Y value being drawn as a line
- static member Range(xy, upper, lower,?Name,?ShowMarkers,?Showlegend,?Color,?RangeColor,?Labels,?TextPosition,?TextFont) =
- let x,y = Seq.unzip xy
- Chart.Range(x, y, upper, lower, ?Name=Name,?ShowMarkers=ShowMarkers,?Showlegend=Showlegend,?Color=Color,?RangeColor=RangeColor,?Labels=Labels,?TextPosition=TextPosition,?TextFont=TextFont)
-
-
- /// Displays a range of data by plotting two Y values per data point, with each Y value being drawn as a line
- static member Range(x, y, upper, lower,mode,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?Color,
- [] ?RangeColor,
- [] ?Labels,
- [] ?UpperLabels,
- [] ?LowerLabels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?LowerName: string,
- [] ?UpperName: string) =
-
- let upperName = defaultArg UpperName "upper"
- let lowerName = defaultArg LowerName "lower"
-
- // if text position or font is set than show labels (not only when hovering)
- let changeMode =
- let isShowMarker =
- match ShowMarkers with
- | Some isShow -> isShow
- | Option.None -> false
- StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
- >> StyleParam.ModeUtils.showMarker (isShowMarker)
-
- let trace =
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = y, Mode=mode, ?Fillcolor=Color) )
- |> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend)
- |> TraceStyle.Line(?Color=Color)
- |> TraceStyle.Marker(?Color=Color)
- |> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let lower =
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = lower, Mode=StyleParam.Mode.Lines, ?Fillcolor=RangeColor) )
- |> TraceStyle.TraceInfo(?Name = Some lowerName, Showlegend=false)
- |> TraceStyle.Line(Width=0.)
- |> TraceStyle.Marker(Color=if RangeColor.IsSome then RangeColor.Value else "rgba(0,0,0,0.5)")
- |> TraceStyle.TextLabel(?Text=LowerLabels,?Textposition=TextPosition,?Textfont=TextFont)
-
- let upper =
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = upper, Mode=StyleParam.Mode.Lines, ?Fillcolor=RangeColor, Fill=StyleParam.Fill.ToNext_y) )
- |> TraceStyle.TraceInfo(?Name = Some upperName, Showlegend=false)
- |> TraceStyle.Line(Width=0.)
- |> TraceStyle.Marker(Color=if RangeColor.IsSome then RangeColor.Value else "rgba(0,0,0,0.5)")
- |> TraceStyle.TextLabel(?Text=UpperLabels,?Textposition=TextPosition,?Textfont=TextFont)
-
- GenericChart.MultiChart ([lower;upper;trace],Layout(),Config(), DisplayOptions())
-
-
- /// Displays a range of data by plotting two Y values per data point, with each Y value being drawn as a line
- static member Range(xy, upper, lower, mode,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?Color,
- [] ?RangeColor,
- [] ?Labels,
- [] ?UpperLabels,
- [] ?LowerLabels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?LowerName,
- [] ?UpperName) =
- let x,y = Seq.unzip xy
- Chart.Range(x, y, upper, lower, mode, ?Name=Name,?ShowMarkers=ShowMarkers,?Showlegend=Showlegend,?Color=Color,?RangeColor=RangeColor,?Labels=Labels,?UpperLabels=UpperLabels,?LowerLabels=LowerLabels,?TextPosition=TextPosition,?TextFont=TextFont,?LowerName=LowerName,?UpperName=UpperName)
-
-
- /// Emphasizes the degree of change over time and shows the relationship of the parts to a whole.
- static member Area(x, y,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [] ?Dash,
- [] ?Width) =
- // if text position or font is set than show labels (not only when hovering)
- let changeMode =
- let isShowMarker =
- match ShowMarkers with
- | Some isShow -> isShow
- | Option.None -> false
- StyleParam.ModeUtils.showText (TextPosition.IsSome || TextFont.IsSome)
- >> StyleParam.ModeUtils.showMarker (isShowMarker)
-
- Trace.initScatter (
- TraceStyle.Scatter(X = x,Y = y, Mode=changeMode StyleParam.Mode.Lines,Fill=StyleParam.Fill.ToZero_y) )
- |> TraceStyle.TraceInfo(?Name=Name,?Showlegend=Showlegend,?Opacity=Opacity)
- |> TraceStyle.Line(?Color=Color,?Dash=Dash,?Width=Width)
- |> TraceStyle.Marker(?Color=Color,?Symbol=MarkerSymbol)
- |> TraceStyle.TextLabel(?Text=Labels,?Textposition=TextPosition,?Textfont=TextFont)
- |> GenericChart.ofTraceObject
-
-
- /// Emphasizes the degree of change over time and shows the relationship of the parts to a whole.
- static member Area(xy,
- [] ?Name,
- [] ?ShowMarkers,
- [] ?Showlegend,
- [] ?MarkerSymbol,
- [] ?Color,
- [] ?Opacity,
- [] ?Labels,
- [] ?TextPosition,
- [] ?TextFont,
- [