Python ASSIGNMENT
NB:
Show the code for every steps(i-v) and parts(A-C) with explanations
The dataset attached contain training(training data.csv) and testing data(testing data.csv) comprising the atmospheric pressure measurement taken on the surface(INPUT) and various heights(Y) of the atmosphere as recorded by a radiosonde.
Part A.
i) display in histogram the measurement at various height with respect to the surface to determine if the data is normalize or not
ii) using the training data.csv, run a correlation coefficient for all the heights against the surface
i.e. between 500m and surface(INPUT), 1000m and surface(INPUT) e.t.c.
iii) Plot each of the correlation results against the various heights(500, 1000, 1500m, 6000m 11000m) with the correlation coefficient on the Y-axis and heights on the X-axis
Part B Regression analysis
bi) using the training data develop a regression model based on linear regression Y = mX b (or choose anyone you think is best fit based on correlation test) to predict the pressure at each height using the INPUTs as X and the values at each height as Y.
m and b are the weighting functions.
So there will be five regression models(equations).
b ii) use the testing data surface data(INPUT) and the establish models to predict the pressure at each of the heights. NB: the inputs(X) to predict pressure at each height(Y) will be the surface data(INPUT) only from the test data using the established model and weighting functions
biii) Plot the predicted(at 500, 1000m, 1500, 6000, 11000m) against the observed(the test data @ 500,1000,15000m,6000m,11000m) in a five subplots.
include in the plots the equations of linear fit and r2(coefficient of determination)
biv) compute the Root mean square error of each of the predicted and observed.
Part C Neural Network
ci) Using the training data design a neural network based on the Feed Forward Neural Network (Multilayer Perceptron MLP) with backpropagation algorithm to predict the pressure at each of the heights using the observed data(Target) as inputs. The training data should be used to train the model
cii) show/display the final architecture that of the design model similar to the one shown below
Indicate the number of hidden nodes that gave the closest prediction
cii) use the neural network designed to predict the pressure (Outputs) from the observed(Targets) at the various heights
civ) plot the graph of the predicted pressure at 500m, 1000m, 1500m, 6000m, 11000m by the Neural network against the observed(Target) pressure at these heights from including the equations and r in the plot similar to what is shown below:
cv) compute the root mean square error for pressure predicted by the Neural network for each of the heights.
Part D. Comparison
Plot in five separate plots or subplots the predictions by regression models and the predictions by neural network including the equations or the r2. Include legends to distinguish between result by regression result by neural net. indicate the heights on the plots
Part D should be similar to the example shown below
The idea of this project is to use the readily available input data(INPUTS) to predict pressure at each heights(500m, 1000m, 1500m, 6000m, 11000m)
Note: This should be done in python
The code should have an explanation
Link to dataset:
https://drive.google.com/drive/folders/1DteO-Lcrjq…
The post Python project on regression and neural network models appeared first on learnedprofessors.