Ejemplo n.º 1
0
        public void TestMath()
        {
            var stats = new GameStats();
            stats.RushingStats.ListRushAtt = new List<int>{5, 10, 15, 20, 25};

            Assert.AreEqual(15.0, stats.RushingStats.ListRushAtt.Mean());
            Assert.AreEqual(50.0, stats.RushingStats.ListRushAtt.Variance());
            Assert.AreEqual(7.0710678118654755, stats.RushingStats.ListRushAtt.StandardDeviation());
        }
Ejemplo n.º 2
0
 private GameStats InitializeGameModel()
 {
     var returnModel = new GameStats
     {
         PassingStats = new GameStats.PassStats
         {
             CompletedPasses = new List<int>(),
             PassAttempts = 0,
             PassInt = 0,
             PassTd = 0,
             Sacks = new List<int>()
         },
         RushingStats = new GameStats.RushStats
         {
             ListRushAtt = new List<int>(),
             RushTd = 0,
             Fumbles = 0
         },
         SpecTeams = new GameStats.Special { 
             FgMade = new List<int>(),
             FgMissed = new List<int>(),
             KickoffLength = new List<int>(),
             KickReturnYards = new List<int>(),
             PuntReturnYards = new List<int>(),
             PuntYards = new List<int>(),
             StartingPoint = new List<int>(),
         }
     };
     return returnModel;
 }