---
title: geo.strictFilter() function
description: geo.strictFilter() filters data by latitude and longitude in a specified region.
url: https://docs.influxdata.com/flux/v0/stdlib/experimental/geo/strictfilter/
estimated_tokens: 1379
product: Flux
version: v0
---

# geo.strictFilter() function

-   Flux 0.63.0+
-   View InfluxDB support

`geo.strictFilter()` is experimental and [subject to change at any time](/flux/v0/stdlib/experimental/#experimental-packages-are-subject-to-change).

`geo.strictFilter()` filters data by latitude and longitude in a specified region.

This filter is more strict than `geo.gridFilter()`, but for the best performance, use `geo.strictFilter()` after `geo.gridFilter()`. Input rows must have `lat` and `lon` columns.

##### Function type signature

```js
(<-tables: stream[{B with lon: D, lat: C}], region: A) => stream[{B with lon: D, lat: C}] where A: Record
```

For more information, see [Function type signatures](/flux/v0/function-type-signatures/).

## Parameters

### region

(Required) Region containing the desired data points.

Specify record properties for the shape.

### tables

Input data. Default is piped-forward data (`<-`).

## Examples

### Strictly filter data to a specified region

```js
import "experimental/geo"

data
    |> geo.strictFilter(region: {lat: 40.69335938, lon: -73.30078125, radius: 50.0})
```

[](#view-example-input-and-output)

View example input and output

#### Input data

| _time | *id | lat | lon | *s2_cell_id |
| --- | --- | --- | --- | --- |
| 2021-01-03T02:00:00Z | a213b | 39.08433 | -75.9978 | 89bc |

| _time | *id | lat | lon | *s2_cell_id |
| --- | --- | --- | --- | --- |
| 2021-01-01T00:00:00Z | a213b | 41.01433 | -70.7515 | 89e4 |

| _time | *id | lat | lon | *s2_cell_id |
| --- | --- | --- | --- | --- |
| 2021-01-02T01:00:00Z | a213b | 40.9228 | -73.3527 | 89ec |

#### Output data

| _time | *id | lat | lon | *s2_cell_id |
| --- | --- | --- | --- | --- |
| 2021-01-02T01:00:00Z | a213b | 40.9228 | -73.3527 | 89ec |

#### Related

-   [geo.gridFilter() function](/flux/v0/stdlib/experimental/geo/gridfilter/)
-   [geo.filterRows() function](/flux/v0/stdlib/experimental/geo/filterrows/)
-   [geo.toRows() function](/flux/v0/stdlib/experimental/geo/torows/)
-   [Work with geo-temporal data](/influxdb/v2/query-data/flux/geo/)

[transformations](/flux/v0/tags/transformations/) [filters](/flux/v0/tags/filters/) [geotemporal](/flux/v0/tags/geotemporal/)
