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
Illustration of script: For illustration, we will now generate a script known as script1.m which calculates area of the circle. It assigns a value for the radius, and then com

Hi, I need help with solving five-1st order ODE which are coupled. I need to plot these as well. Could I please get a quote. Thanks

#question how to solve radicals exponents..

You are given data similar to the examples and sample problems in the statistics topic. Write MATLAB program to do the following: 1. Plot histogram, relative frequency histogram

Diary Files: Before doing this assignment, please read the document Notes on Matlab Assignments (available from the course web page). It describes how to record the results of your

Example of Variables and assignment statements: The expression is computed and then that value is stored in the variable. For illustration, this is the way it would appear in

Functions which return More than one Value: Functions which return one value have one output argument. The Functions which return more than one value should rather have more t


The IF-ELSE Statement: The if statement selects whether an action is executed or not. Selecting between the two actions, or selecting from numerous actions, is accomplished by

Create a custom chi-square function in matlab, MATLAB in Statisticsn..