Beispiel #1
0
 IEnumerable <Parameter1DimensionalMember <T> > IParameter1DimensionalTypeless <T> .GetEnumerator()
 {
     foreach (var i in _values.GetEnumerator())
     {
         yield return(i);
     }
 }
Beispiel #2
0
        public YearFieldWindow(string parameterName, IParameter1Dimensional<Timestep, double> parameterToDisplay)
        {
            InitializeComponent();

            _parameter = parameterToDisplay;
            _parameterName = parameterName;

            plotterHeader.Content = parameterName;
            //var l = new System.Windows.Controls.DataVisualization.Charting.LineSeries();
            var data = from p in parameterToDisplay.GetEnumerator()
                       where !Double.IsNaN(p.Value) && !double.IsInfinity(p.Value)
                       select new Point(p.Dimension1.Index + 1950, p.Value);

            var d = data.AsDataSource();

            plotter.AddLineGraph(d);
        }
        public YearFieldWindow(string parameterName, IParameter1Dimensional <Timestep, double> parameterToDisplay)
        {
            InitializeComponent();

            _parameter     = parameterToDisplay;
            _parameterName = parameterName;

            plotterHeader.Content = parameterName;
            //var l = new System.Windows.Controls.DataVisualization.Charting.LineSeries();
            var data = from p in parameterToDisplay.GetEnumerator()
                       where !Double.IsNaN(p.Value) && !double.IsInfinity(p.Value)
                       select new Point(p.Dimension1.Index + 1950, p.Value);


            var d = data.AsDataSource();

            plotter.AddLineGraph(d);
        }