{EPITECH} | Second year | Math project
The world population growth is a cause for concern for most people: 1 billion people in 1800, 2 billion people in 1927, 6 billion people in 2000 and more than 7.5 billion people today... Predicting future population using past censuses is therefore a key concept.
Along with this subject, you will find a file named 207demography_data.csv, which gives an estimation of every country’s population from 1960 onwards. If world population growth seems exponential in the long-term, in a shorter term it seems linear: using this data, you must establish the linear least squares regression that will allow you to predict population depending on the year.
In the following, Yis the population (in million people) and Xthe year. With one or several country codes as inputs, your program will print:
- the aXand bXcoefficients of the linear fit Y= aXX+ bX,
- the root-mean-square deviation of this fit,
- the population prediction in 2050 according to this fit,
- the aYand bYcoefficients of the linear fit X= aYY+ bY,
- the root-mean-square deviation of this fit,
- the population prediction in 2050, according to this fit,
- the correlation coefficient between Xand Y
See the subject for further details !
========================
Grade : A | Mark : 20
Category | Percentage | Tests | Crash ? |
---|---|---|---|
basic | 100% | 6/6 | x |
correlation | 100% | 3/3 | x |
correlation (eval) | 100% | 3/3 | x |
fits | 100% | 6/6 | x |
rigor | 100% | 4/4 | x |
End score | 100% | 22/22 | No |
Made with Quentin TREHEUX (LuciferBahamut)
Beware of -42 Epitech students !!!