Write a program to calculates the standard deviation, MATLAB Programming

Write a program that reads in numbers (of type double) from a file, stores them in an array, and then calculates the mean, variance, and standard deviation.  

Your program should solve the problem by using the following methods implemented in a class..named Calculate.java  

This class should implement the following methods:

1.  One method to count the number of data numbers in the input file. This method should:

o  be public and static

o  be named  countData

o  accept a String representing the filename

o  return an integer that represents the number of numbers in the data file

2.  One method to read the numbers and the data file. This method should:

o  be public and static

o  be named  readData

o  accept a String representing the filename, and a parameter for an array of type double

3.  One method to calculate the mean value

This method should:

o  be public and static

o  be named  calMean

o  accept an array of type double

o  return the calculated mean as a number of type double

4.  One method to calculate the variance

This method should:

o  be public and static

o  be named  calVariance

o  accept an array of type double and the calculated mean value as a double

o  return the calculated variance as a number of type double

Posted Date: 2/27/2013 6:54:02 AM | Location : United States







Related Discussions:- Write a program to calculates the standard deviation, Assignment Help, Ask Question on Write a program to calculates the standard deviation, Get Answer, Expert's Help, Write a program to calculates the standard deviation Discussions

Write discussion on Write a program to calculates the standard deviation
Your posts are moderated
Related Questions
how to implement 3 out of 4 visual cryptography?


Variable names: Variable names are an example of the identifier names. The rules for identifier names are as shown below: (A)The name should begin with a letter of the alph

Write a program that reads in numbers (of type double) from a file, stores them in an array, and then calculates the mean, variance, and standard deviation.   Your program shoul

Q. The steady-state circuit i(t) in a series RL circuit due to a periodic sawtooth voltage is given by where θ n = tan -1 (nω 0 L/R).With the parameters V A = 25 V, T 0

how to create adjacency matrix for amino acids in matlab?

Code and decode a 32 bit long data for a specific user in CDMA if there is only 1 user and no noise.

Show (turn in) similar output images as in part 2 for each of your new images (there is only 1 connected component in this case). Write three functions which compute the moments, c


Problem: A function is given by Y= 2x3 + 3 x2 -12x + 5 a determine the finite values of x at which any local maximum of minimum occur and determine the corresponding val