Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

我们为许可用户提供了部分翻译好的中文文档。您只需登录便可查阅这些文档

Pie Charts, Bar Plots, and Histograms

Proportion and distribution of data

Functions

bar Bar graph
bar3 Plot 3-D bar graph
barh Plot bar graph horizontally
bar3h Plot horizontal 3-D bar graph
histogram Histogram plot
histcounts Histogram bin counts
histogram2 Bivariate histogram plot
histcounts2 Bivariate histogram bin counts
rose Angle histogram plot
pareto Pareto chart
area Filled area 2-D plot
pie Pie chart
pie3 3-D pie chart

Using Objects

histogram Histogram bar plot for numeric data
histogram2 Histogram bar plot for bivariate data

Properties

Bar Series Properties Control bar series appearance and behavior
Area Properties Control area appearance and behavior
Histogram Properties Control histogram appearance and behavior
Histogram2 Properties Control histogram2 appearance and behavior

Examples and How To

Modify Baseline of Bar Graph

This example shows how to modify properties of the baseline of a bar graph.

Overlay Bar Graphs

This example shows how to overlay two bar graphs and specify the bar colors and widths.

Combine Line and Bar Charts Using Two y-Axes

This example shows how to combine a line chart and a bar chart using two different y-axes.

Color 3-D Bars by Height

This example shows how to modify a 3-D bar plot by coloring each bar according to its height.

Compare Data Sets Using Overlayed Area Graphs

This example shows how to compare two data sets by overlaying their area graphs.

Offset Pie Slice with Greatest Contribution

This example shows how to create a pie graph and automatically offset the pie slice with the greatest contribution.

Add Legend to Pie Chart

This example shows how to add a legend to a pie chart that displays a description for each slice.

Label Pie Chart With Text and Percentages

This example shows how to label slices on a pie chart so that the labels contain custom text and the precalculated percent values for each slice.

Color Analysis with Bivariate Histogram

This example shows how to adjust the color scale of a bivariate histogram plot to reveal additional details about the bins.

Replace Discouraged Instances of hist and histc

histogram, histcounts, and discretize are the recommended histogram creation and computation functions for new code.

Concepts

Types of Bar Graphs

Bar graphs are useful for viewing results over a period of time, comparing results from different data sets, and showing how individual elements contribute to an aggregate amount.

Data Cursors with Histograms

When you use the Data Cursor tool on a histogram plot, it customizes the data tips it displays in an appropriate way.

Was this topic helpful?