# Timelion filter

**URL:** https://discuss.elastic.co/t/timelion-filter/75787
**Category:** Kibana
**Tags:** timelion
**Created:** [February 20, 2017, 6:55pm UTC](https://discuss.elastic.co/t/timelion-filter/75787 "2017-02-20T18:55:19Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Tomaz\_Bratanic](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tomaz_bratanic/32/15713_2.png) [@Tomaz\_Bratanic](https://discuss.elastic.co/u/Tomaz_Bratanic)
#### Post date: [February 20, 2017, 6:55pm UTC](https://discuss.elastic.co/t/timelion-filter/75787/1 "2017-02-20T18:55:19Z")

</div>

I have created my timelion visualization using for month over month % of new users

> .es(index=index,timefield=time,metric=cardinality:company)  
> .divide(.es(index=index,timefield=time,metric=cardinality:company,offset=-1M)  
> .cusum()).bars()

Is there any way to put filter directly into timelion expression, lets say sequence : 1,  
which means the only the first orders, so that numbers are correct, otherwise it is not.  
I know I can set the filter on the dashboard but i dont like that because it ruins my other stats.

Thanks

---

<div class="post-metadata">

### Author: ![weltenwort](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/weltenwort/32/53885_2.png) [@weltenwort](https://discuss.elastic.co/u/weltenwort)
#### Post date: [February 20, 2017, 7:57pm UTC](https://discuss.elastic.co/t/timelion-filter/75787/2 "2017-02-20T19:57:18Z")

</div>

Hi @Tomaz_Bratanic,

you can specify a [lucene query string](https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-query-string-query.html#query-string-syntax) as the `q` argument to `.es()` as in

```
.es(q=sequence:1,index=index,timefield=time,metric=cardinality:company)

```

That query string would only affect this time series and not interfere with the rest of your dashboard.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [March 20, 2017, 7:57pm UTC](https://discuss.elastic.co/t/timelion-filter/75787/3 "2017-03-20T19:57:32Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
