This topic describes how to configure a flow diagram to display query results. It also includes examples.
The flow diagram, also known as ThemeRiver, is a stacked area chart around the central axis. The banded branches with different colors indicate different categorical data. The band width indicates the numeric value. The time information of the data is configured on the X-axis of the chart by default. A flow diagram displays data from three dimensions.
You can convert a flow diagram to a line chart or column chart. The column chart is stacked by default. Each category of data starts from the top of the last categorical data.
- X-axis (horizontal)
- Y-axis (vertical)
- On the Search & Analysis page of a Logstore, enter a search and analytics statement
in the search box, specify the time range, and then click Search & Analyze.
The Chart tab is automatically displayed when a query is completed.
- Click to display the query results in a pie chart.
- On the Properties tab on the right, configure the properties of the table.
Configuration item Description Chart Types The type of the chart. Valid values: Line Chart, Area Chart, and Column Chart. Default value: Line Chart. X Axis The data on the X-axis, which is usually a time sequence. Y Axis The numeric data. You can configure one or more fields on the Y-axis. Aggregate Column The information required to be aggregated in the third dimension. Legend The position where the legend is located in the chart. Valid values: Top, Bottom, Left, and Right. Format The format in which data is displayed. Items per Page The number of entries to return on each page. This item is available only when you set Chart Types to Scatter with Smooth Lines and Markers. Margin The distance of the axis to the borders of the chart, including Top Margin, Bottom Margin, Right Margin, and Left Margin.
The flow diagram is suitable to display data from three dimensions, including the time information, categories, and numeric values.
* | select date_format(from_unixtime(__time__ - __time__% 60), '%H:%i:%S') as minute, count(1) as c, request_method group by minute, request_method order by minute asc limit 100000
minute for X Axis,
c for Y Axis, and
request_method for Aggregate Column.