Example of file ploting data, MATLAB in Engineering

Assignment Help:

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


Related Discussions:- Example of file ploting data

Finding products by for loop, Finding products by for loop: an illustr...

Finding products by for loop: an illustration, when 5 is passed to be the value of the input argument n, the function will compute and return 1 + 2 + 3 + 4 + 5, or 15: >> s

For loops - iterator variable, For Loops which do not use an iterator Vari...

For Loops which do not use an iterator Variable in the action: In all the illustrations that we seen so far, the value of the loop variable has been used in same way in the ac

Distributed computing on linux cluster, i want to run 4 instances of my mat...

i want to run 4 instances of my matlab code on 4 processor cores. im executing the job from head node. i created a parallel job and assigned number of workers. but i don''t get bac

Symbolic variables and expressions, Symbolic Variables and expressions: ...

Symbolic Variables and expressions: The MATLAB has a type known as sym for the symbolic variables and expressions; these work with strings. The illustration, to generate a sym

Illustration of sound signals, Illustration of Sound files: For illust...

Illustration of Sound files: For illustration, the following script generates a subplot which shows the signals from chirp and from train, which is as shown in figure:

Calcrectarea subfunction, calcrectarea subfunction: function call: ar...

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

Image processing, Image Processing: The Images are represented as grid...

Image Processing: The Images are represented as grids, or matrices, of picture elements (known as pixels). In MATLAB an image usually is represented as a matrix in which each

Filter, A matlab function to calculate filter order

A matlab function to calculate filter order

Creating the structure variables, Creating the structure Variables: Cr...

Creating the structure Variables: Creating a structure variable can be accomplished by simply storing the values in fields by using assignment statements, or by using the stru

Anonymous functions, Anonymous Functions: The anonymous function is a ...

Anonymous Functions: The anonymous function is a very easy, one-line function. The benefit of an anonymous function is that it does not have to be stored in an M-file. This ca

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd