<commit_before>import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Scanner;

public class Bot {
	static final String ds = "$";
	
	public static void main(String[] args) throws IOException {
		/*
		Symbol symbol;
		Scanner sc = new Scanner(System.in);
		
		
		// Get a stock symbol to check
		System.out.print("Stock: ");
		String stock = sc.next();
		symbol = new Symbol(stock);
		

		symbol = new Symbol("AAPL");


		System.out.println("Symbol: " + symbol.getSymbol());
		System.out.println("Price: " + ds + symbol.getPrice());
		// System.out.println("Shares: " + symbol.getNumberOfShares());
		System.out.println("Moving Average: " + symbol.getMA(0, 200));
		System.out.println("Moving Average: " + symbol.getMA(0, 50));
		// System.out.println("Closing Price: " + symbol.getAdjClose(30));
		*/

		
		//Symbol[] trainingSet = getRandomStocks(5);
		Symbol[] trainingSet = new Symbol[5];
		trainingSet[0] = new Symbol("HD");
		trainingSet[1] = new Symbol("HP");
		trainingSet[2] = new Symbol("ABC");
		trainingSet[3] = new Symbol("GOOGL");
		trainingSet[4] = new Symbol("MMM");
		
		double[] weightsArray = RegressionAlgorithm.linearLearner(trainingSet, 10, 0.000001);
		
		Symbol appleSymbol = new Symbol("AAPL");
		double prediction = RegressionAlgorithm.predictY(appleSymbol, 10, weightsArray);
		System.out.print("Actual: " + appleSymbol.getPrice().doubleValue() + ", Predicted: " + prediction);

		//sc.close();
	}
	
	private static Symbol[] getRandomStocks(int num) throws IOException {<commit_msg>Cleaned up old code<commit_after>import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Scanner;

public class Bot {
	static final String ds = "$";
	
	public static void main(String[] args) throws IOException {
	}
	
	private static Symbol[] getRandomStocks(int num) throws IOException {
{'fraction_non_alphanumeric': 0.14799588900308325, 'fraction_numerical': 0.013874614594039054, 'mean_word_length': 4.515580736543909, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5848076', 'n_tokens_mistral': 674, 'n_tokens_neox': 598, 'n_words': 146}