I have a map object with geojson data as source. each features is like :
{
"id": "0",
"type": "Feature",
"properties": {
"color": "#377eb8",
"edge_id": 1,
"time": [6, 7, 8]
"speed_out": [50, 48, 46]
},
"geometry": {
"type": "Polygon",
"coordinates": [....]
}
}
speed_out property is an array. It's the speed recorded at eah following time: 6AM, 7AM and 8AM.
I would like to apply setFilter in speed_out to change my layer's filter property whenever the input event fires (for example at 6 or 7 or 8).
I try this without succes.
map.setFilter('lines', ['==', ['number', ['get', 'speed_out']], time]);
Could you please helpe me