How do I plot a histogram for large data sets?

조회 수: 1 (최근 30일)
Fope Ayo
Fope Ayo 2019년 6월 12일
댓글: Fope Ayo 2019년 6월 13일
Can anyone possibly help me with writing a code for my histogram?
I need to use matlab but I'm not familiar with histograms and the information page is not helping too much.
Essentially I have 355 data points, then the raw data for all those data points.
I want to plot Number of Cells against Fluorescence Intensity
x (Fluorescence Intensity)
y (Number of cells)
I can determine the directory and file name, but I do not know how to write the code to generate the histogram after that.
The data will be imported from an excel file, just FYI.
  댓글 수: 6
Prasanth Sikakollu
Prasanth Sikakollu 2019년 6월 13일
This is actually not a histogram. It is a bar graph you are looking for.
Fope Ayo
Fope Ayo 2019년 6월 13일
Then it wasn’t what I was looking for

댓글을 달려면 로그인하십시오.

답변 (1개)

Prasanth Sikakollu
Prasanth Sikakollu 2019년 6월 13일
The basic difference between histogram and bar chart is:
Histogram refers to a graphical representation; that displays data by way of bars to show the frequency of numerical data. A bar graph is a pictorial representation of data that uses bars to compare different categories of data.
A Bar chart is apt for your problem. This should work.
dataset = xlsread('histogram data for glucose.xlsx');
x = dataset(:,1);
y = dataset(:,2);
bar(x,y);

카테고리

Help CenterFile Exchange에서 Data Distribution Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by