public PivotResult(PopulationPivotAnalysis analysis, DataTable pivotedData, IPopulationDataCollector populationDataCollector, ObservedDataCollection observedDataCollection, string aggregationName, string dataColumnName) { Analysis = analysis; PivotedData = pivotedData; PopulationDataCollector = populationDataCollector; ObservedDataCollection = observedDataCollection; AggregationName = aggregationName; DataColumnName = dataColumnName; }
public void UpdateFrom(ObservedDataCollection observedDataCollection) { if (observedDataCollection == null) { return; } observedDataCollection.AllObservedData().Each(AddObservedData); observedDataCollection.ObservedDataCurveOptions().Each(AddCurveOptions); ApplyGroupingToObservedData = observedDataCollection.ApplyGroupingToObservedData; }
protected PopulationAnalysisChart() { Id = ShortGuid.NewGuid(); ChartSettings = new ChartSettings(); ObservedDataCollection = new ObservedDataCollection(); Name = string.Empty; Title = string.Empty; FontAndSize = new ChartFontAndSizeSettings(); _secondaryYAxisSettings = new List <AxisSettings>(); PrimaryXAxisSettings = new AxisSettings(); PrimaryYAxisSettings = new AxisSettings(); }
protected override Task Context() { _curveOptionsMapper = A.Fake <CurveOptionsMapper>(); sut = new ObservedDataCollectionMappper(_curveOptionsMapper); _observedDataRepository = DomainHelperForSpecs.ObservedData("ID").WithName("ObsData"); _observedDataCollection = new Model.PopulationAnalyses.ObservedDataCollection(); _observedDataCollection.ApplyGroupingToObservedData = true; _observedDataCollection.AddObservedData(_observedDataRepository); _firstObservedDataColumn = _observedDataRepository.ObservationColumns().First(); _observedDataCurveOptions = new ObservedDataCurveOptions { Caption = "Obs Data Caption", ColumnId = _firstObservedDataColumn.Id }; _observedDataCollection.AddCurveOptions(_observedDataCurveOptions); _snapshotCurveOptions = new CurveOptions(); A.CallTo(() => _curveOptionsMapper.MapToSnapshot(_observedDataCurveOptions.CurveOptions)).Returns(_snapshotCurveOptions); return(_completed); }
protected override async Task Because() { _result = await sut.MapToModel(null, new SimulationAnalysisContext()); }
protected override async Task Because() { _newObservedDataCollection = await sut.MapToModel(_snapshot, _simulationAnalysisContext); }
public void AddObservedData(DataRepository dataRepository) { ObservedDataCollection.AddObservedData(dataRepository); }
public CurveOptions CurveOptionsFor(DataColumn dataColumn) { return(ObservedDataCollection.ObservedDataCurveOptionsFor(dataColumn).CurveOptions); }
public void RemoveObservedData(DataRepository dataRepository) { ObservedDataCollection.RemoveObservedData(dataRepository); }
public bool UsesObservedData(DataRepository dataRepository) { return(ObservedDataCollection.UsesObservedData(dataRepository)); }
public IEnumerable <DataRepository> AllObservedData() { return(ObservedDataCollection.AllObservedData()); }