Skip to content

Commit 5ad8ea2

Browse files
authored
[DOCS] Fixes geo function field names. (#83198) (#83200)
1 parent a059051 commit 5ad8ea2

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

docs/reference/ml/anomaly-detection/functions/ml-geo-functions.asciidoc

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ PUT _ml/anomaly_detectors/example1
3636
"analysis_config": {
3737
"detectors": [{
3838
"function" : "lat_long",
39-
"field_name" : "transactionCoordinates",
40-
"by_field_name" : "creditCardNumber"
39+
"field_name" : "transaction_coordinates",
40+
"by_field_name" : "credit_card_number"
4141
}]
4242
},
4343
"data_description": {
@@ -50,22 +50,23 @@ PUT _ml/anomaly_detectors/example1
5050

5151
If you use this `lat_long` function in a detector in your {anomaly-job}, it
5252
detects anomalies where the geographic location of a credit card transaction is
53-
unusual for a particular customer’s credit card. An anomaly might indicate fraud.
53+
unusual for a particular customer’s credit card. An anomaly might indicate
54+
fraud.
5455

55-
IMPORTANT: The `field_name` that you supply must be a single string that contains
56-
two comma-separated numbers of the form `latitude,longitude`, a `geo_point` field,
57-
a `geo_shape` field that contains point values, or a `geo_centroid` aggregation.
58-
The `latitude` and `longitude` must be in the range -180 to 180 and represent a
59-
point on the surface of the Earth.
56+
IMPORTANT: The `field_name` that you supply must be a single string that
57+
contains two comma-separated numbers of the form `latitude,longitude`, a
58+
`geo_point` field, a `geo_shape` field that contains point values, or a
59+
`geo_centroid` aggregation. The `latitude` and `longitude` must be in the range
60+
-180 to 180 and represent a point on the surface of the Earth.
6061

6162
For example, JSON data might contain the following transaction coordinates:
6263

6364
[source,js]
6465
--------------------------------------------------
6566
{
6667
"time": 1460464275,
67-
"transactionCoordinates": "40.7,-74.0",
68-
"creditCardNumber": "1234123412341234"
68+
"transaction_coordinates": "40.7,-74.0",
69+
"credit_card_number": "1234123412341234"
6970
}
7071
--------------------------------------------------
7172
// NOTCONSOLE

0 commit comments

Comments
 (0)