Example of file ploting data, MATLAB in Engineering

Example of file ploting data:

As the other example, a data file called 'compsales.dat' stores the sales figures (in millions) for divisions in a company.

Each line in the file stores the sales number, followed by an short form of the division name, in the following format which is as shown below:

5.2 X

3.3 A

5.8 P

2.9 Q

 

The script below uses the textscan function to read this information into a cell array, and then uses the subplot to produce a Figure Window which displays the information in a bar chart and in a pie chart as shown in figure.

812_example of plting file data.png

1512_example of plting file data1.png

Posted Date: 10/22/2012 2:25:02 AM | Location : United States







Related Discussions:- Example of file ploting data, Assignment Help, Ask Question on Example of file ploting data, Get Answer, Expert's Help, Example of file ploting data Discussions

Write discussion on Example of file ploting data
Your posts are moderated
Related Questions
Interchange rows : for illustration interchanging rows ri and rj is written as

Plotting File data: It is frequently essential to read data from a file and plot it. Generally, this entails knowing the format of the file. For illustration, let us suppose t

IS Functions in Matlab: There are many functions which are built into MATLAB which test whether or not something is true; these function names start with the word is. As these

Function rmfield - structure: The function rmfield eliminates a field from the structure. It returns a new structure with field eliminated, but does not modify the original st

Passing arguments to functions: In all these functions examples faraway, at least one of the arguments was passed in the function call to be the value(s) of the equivalent inp

function numden: The function numden will return individually the numerator & denominator of a symbolic expression: >> sym(1/3 + 1/2) ans = 5/6 >> [n, d] =

calcrectarea subfunction: function call: area = calcrectarea(len,wid); function header: function area = calcrectarea(len, wid)   In the function call, the two arg

A matlab function to calculate filter order

Creating a cell array: The other method of creating a cell array is easy to assign values to particular array elements and build it up element by element. Though, as explained

Use of built-in colormaps: MATLAB has built-in colormaps, it is also possible to generate others by using combinations of any colors. For illustration, the following generates