Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Per visualization field formatters #4957

Closed
GrahamHannington opened this issue Sep 16, 2015 · 18 comments
Closed

Per visualization field formatters #4957

GrahamHannington opened this issue Sep 16, 2015 · 18 comments
Labels
Feature:FieldFormatters Feature:Visualizations Generic visualization features (in case no more specific feature label is available) release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure

Comments

@GrahamHannington
Copy link

I have a bar chart visualization that uses the Date Range aggregation. Each range spans 1 hour. I want the corresponding x-axis labels to look like this: "9am to 10am". I can do that by changing the value of the ("global") Kibana dateFormat setting to ha (from its default of MMMM Do YYYY, HH:mm:ss.SSS), but that affects all "pretty formatted dates" in Kibana, which is undesirable.

I want to specify dateFormat per visualization, to override the "global" setting.

I decided to create this issue after I replied to the related existing discussion thread "How can i change the x-axis labels for a date format in Kibana".

@rashidkpc rashidkpc changed the title Date format per visualization Per visualization field formatters Sep 16, 2015
@rashidkpc
Copy link
Contributor

You can change this on a per field basis using field formatters, but not per-visualization, updating issue title

@tcucchietti

This comment has been minimized.

@svenmueller

This comment has been minimized.

@JuanCarniglia
Copy link

In order to achieve this, I have created a visualization (github.com/JuanCarniglia/kbn_picture_values_vis) that allows adjusting format (using numeral.js patterns) for each metric value, and also allows displaying a fontAwesome icon next to the value. Both the color of the value and the picture can change, according to a range the falls into. (i.e. From 0 to 50 RED, 50 to 100 green).

You think it would be nice to create a PR and add this to the metrics vis?

@djschny

This comment has been minimized.

@tbragin tbragin added the Feature:Visualizations Generic visualization features (in case no more specific feature label is available) label Nov 15, 2016
@gitime

This comment has been minimized.

5 similar comments
@quickdraw6906
Copy link

+1

@AliAqdasShah
Copy link

+1

@AlexPadd
Copy link

+1

@kaigrolik
Copy link

+1

@gmatheus
Copy link

gmatheus commented Mar 9, 2018

+1

@timroes timroes added the Team:Visualizations Visualization editors, elastic-charts and infrastructure label Sep 16, 2018
@jefersonestevo

This comment has been minimized.

@datablackhole

This comment has been minimized.

1 similar comment
@mpmman

This comment has been minimized.

@cawoodm
Copy link

cawoodm commented Sep 27, 2019

Agree. Sometimes we count the average (e.g. requests per minute) and it's not possible to set the format on the field since there is no field - documents are counted. If we want out visualization to display 6.6 and not 6.66666667 there is no way currently to achieve this only for the visualization without changing the global number format which is undesirable.

image

@msfreed

This comment has been minimized.

@wylieconlon
Copy link
Contributor

While it doesn't address the oldest part of this request, we will soon have this feature in Lens. #56253

@timroes
Copy link
Contributor

timroes commented Jun 21, 2021

This has been adressed in Lens and released in 7.7, thus closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:FieldFormatters Feature:Visualizations Generic visualization features (in case no more specific feature label is available) release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
None yet
Development

No branches or pull requests