histf

버전 1.0.0.0 (62.4 KB) 작성자: Chad Greene
Simply produce histograms formatted the way you like them.
다운로드 수: 4.9K
업데이트 날짜: 2014/8/15

라이선스 보기

This function plots formatted histograms. It's similar to hist, but with more options for FaceColor, BarWidth, LineStyle, FaceAlpha, etc.

Syntax
histf(Y)
histf(Y,x)
histf(Y,nbins)
histf(...,'BarWidth',BarWidth)
histf(...,'FaceColor',FaceColor)
histf(...,'EdgeColor',EdgeColor)
histf(...,'LineStyle',LineStyle)
histf(...,'LineWidth',LineWidth)
histf(...,'FaceAlpha',FaceAlpha)
histf(...,'EdgeAlpha',EdgeAlpha)
histf(...,'Alpha',Alpha)
[n,xout,h] = histf(...)

Description
histf(Y) bins the elements in vector Y into 10 equally spaced containers and returns the number of elements in each container as a row vector. If Y is an m-by-p matrix, histf treats the columns of Y as vectors. No elements of Y can be complex or of type integer.

histf(Y,x) where x is a vector, returns the distribution of Y among length(x) bins with centers specified by x. For example, if x is a 5-element vector, histf distributes the elements of Y into five bins centered on the x-axis at the elements in x, none of which can be complex.

histf(Y,nbins) where nbins is a scalar, uses nbins number of bins.

histf(...,'BarWidth',BarWidth) specifies the width of bars as a fraction of total space available for each bar. Default BarWidth is 1.

histf(...,'FaceColor',FaceColor) specifies face color as a short name, long name, or RGB triple.

histf(...,'EdgeColor',EdgeColor) specifies edge coloras a short name, long name, or RGB triple.

histf(...,'LineStyle',LineStyle) specifies line style of bar edges. Can be '-' (default), ':', '--', '-.', or 'none'.

histf(...,'LineWidth',LineWidth) specifies line width of bar edge in points. Default LineWidth is 0.5 points.

histf(...,'FaceAlpha',FaceAlpha) specifies transparency value of bar faces. FaceAlpha must be a scalar between 0 and 1. Default value is 1.

histf(...,'EdgeAlpha',EdgeAlpha) specifies transparency value of bar edges. EdgeAlpha must be a scalar between 0 and 1. Default value is 1.

histf(...,'Alpha',Alpha) sets FaceAlpha and EdgeAlpha to Alpha.

[n,xout,h] = histf(...) returns vectors n and xout containing the frequency counts and the bin locations. h is the handle of the newly plotted histogram.

인용 양식

Chad Greene (2024). histf (https://www.mathworks.com/matlabcentral/fileexchange/47552-histf), MATLAB Central File Exchange. 검색 날짜: .

MATLAB 릴리스 호환 정보
개발 환경: R2012b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Data Distribution Plots에 대해 자세히 알아보기
도움

도움 받은 파일: legalpha

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

histf_documentation/html/

버전 게시됨 릴리스 정보
1.0.0.0