/// <summary>
        /// Predicts parity according to given data
        /// </summary>
        /// <param name="data">Data for prediction</param>
        /// <returns>Predicted data</returns>
        public ParityPrediction Predict(ParityData data)
        {
            ParityPrediction result = null;

            if (null != data)
            {
                if (null != _predictionEngine)
                {
                    result = _predictionEngine.Predict(data);
                }
            }

            return(result);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Tests prediction for USD/TR Parity
        /// </summary>
        public static void Predict_USD_TR_Parity()
        {
            ParityPredictor predictor = new ParityPredictor(@".\DATA\Currencies\USD_TR_Parity_1M.csv");

            predictor.Train();

            ParityData data = new ParityData()
            {
                Day   = 3,
                Month = 4,
                Year  = 2019,
                Start = 5.6175f,
                Low   = 5.5705f,
                High  = 5.6588f
            };

            ParityPrediction predictionResult = predictor.Predict(data);

            Console.WriteLine("Prediction: " + predictionResult.Prediction);
            Console.ReadKey();
        }