Skip to content

thapa-jeevan/Linear-Feature-Engineering

Repository files navigation

Project 1: Linear Feature Engineering

This repo consists of codebase for linear feature engineering, the first project for Quantitative Foundations. We use Linear Regression as the learning algorithm. The training data in traindata.txt consists of 926 data points with 8 features and 1 output real value. And, the test data in testinputs.txt consists of 103 data points. Since, the number of training data points is extremely low, we rely on cross validation to avoid overfitting.

To run the codebase, follow the steps below.

  1. Install the dependencies using the following command.
pip install -r requirements.txt
  1. The predictions made by our best least squares model are already dumped to reports/prediction_results.csv file. In order to regenerate the test predictions, using the obtained best model, run the following command. It will write the results to the file.
python main.py --mode test
  1. Run the training pipeline using the following command. It will search the best feature expansion and writes a training visualization of validation MSE scores against different basis settings and the predictions on test set inside results directory.
python main.py --mode train
  1. To visualize the analysis done on the data, run the following command. The visualization results are dumped inside data_viz directory.
python main.py --data-analysis True

About

Project I from CISC.820.01 - Quantitative Foundations

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages