New to Kibana and Elasticsearch, and need some help.
We have files list document that are mainly created during the week, and neither very small number of files list or zero on the weekend.
We are building a moving average graph using Visual Builder, and we would like to remove weekends from the graphs. Is there a way to do this? Show only the weekdays in the x-axis.
Hm, unfortunately I am not aware of any way to exclude weekends from the x-axis if you are looking at days of the week as your interval.
However if you want to be sure you are ignoring the moving average over those days, you could try simply filtering those days out in the Options if you already have the day of the week in your documents.
If you don't have the day of the week in your documents, you could try creating a scripted field* that outputs the day of the week... To take an example from the docs, doc['timestamp'].value.getDayOfWeekEnum() will calculate the day of the week from a timestamp field and return the name as a string.
The only other route I can think of is creating a Vega visualization and experimenting with Vega's conditional axis properties -- I don't know for sure if these will do the trick, but perhaps worth exploring.
*Scripted fields can have a significant performance impact based on how large of a data set you are querying, so the most performant option is always enriching your documents with this info at ingest time.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.