MATLAB Data Analysis and Trigonometric Plotting
Classified in Computers
Written on in
English with a size of 2.6 KB
MATLAB Statistical Analysis of Student Weights
Analyze the weight of 30 students to find the minimum, maximum, average, standard deviation, and plot a histogram.
>> a=[ 71 82 65 75 77 91 59 84 89 81 73 91 82 75 96 85 69 76 81 92 84 79 77 95 81 79 84 85 76 82]
a = Columns 1 through 12
71 82 65 75 77 91 59 84 89 81 73 91
Columns 13 through 24
82 75 96 85 69 76 81 92 84 79 77 95
Columns 25 through 30
81 79 84 85 76 82
>> max(a)
ans = 96
>> min(a)
ans = 59
>> mean(a)
ans = 80.5333
>> std(a)
ans = 8.4516
>> hist(a)Plotting Trigonometric Functions in MATLAB
Follow these steps to plot trigonometric functions:
- Plot the value of the cosine within [0, 2π] with a step of π/20.
- Label the axes and add