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
Application: Menu driven Modular Program Numerous longer, more involved programs which have interaction with the user are menu-driven, that means that the program prints a men

Forward elimination: In forward elimination, we want to obtain a 0 in the a 21 position. To accomplish this, we can alter the second line in the matrix by subtracting from it

Vector operations: As vectors are special cases of matrices, the matrix operations elaborated (addition, subtraction, multiplication, scalar multiplication, transpose) work on

function imread: The function imread can read an image file, for illustration a JPEG (.jpg) file. The function reads color images into a 3-dimensional matrix. >> myimage1

Illustration of anonymous functions: Dissimilar functions stored in the M-files, when no argument is passed to an anonymous function, the parentheses should still be in the fu

1. Write a MATLAB function (upperTriangle) using the functions you previously created to convert a matrix to upper triangular form. Start with row 1, column1. Find the row that has

Matrix operations: There are some common operations on matrices. The operators which are applied term by term, implying that the matrices should be of similar size, sometimes

Example of Exponential function modular program: In order to view the distinction in the approximate value for e as n increases, the user kept choosing Limit & entering larger

Function cirarea - Anonymous functions: The function handle name is cirarea. The one argument is passed to the input argument radius. The body of the function is an expression

Evaluating a string: The function eval is used to compute a string as a function. For illustration, below is the string 'plot(x)'is interpreted to be a call to plot the functi