/// <summary> /// Default constructor. /// </summary> public DatasetInformation() { MetaData = new Dictionary <string, string>(); FactorInformation = new Dictionary <FactorInformation, string>(); Factors = new List <Factor>(); Sequence = null; InputFiles = new List <InputFile>(); IsBaseline = false; PlotData = new DatasetPlotInformation(); ScanTimes = new Dictionary <int, double>(); FeaturesFound = false; IsAligned = false; }
/// <summary> /// Loads dataset information from the path provided. /// </summary> /// <param name="info"></param> /// <returns></returns> public DatasetPlotInformation LoadDatasetPlots(string[] files, DatasetInformation info) { var plotInfo = new DatasetPlotInformation(); var fileList = new List<string>(); fileList.AddRange(files); var datasetFiles = new List<string>(); var name = info.DatasetName.ToLower(); foreach (var filename in fileList) { var file = filename.ToLower(); if (file.Contains(name)) { if (file.Contains("_features")) { plotInfo.Features = file; } else if (file.Contains("_heatmap")) { plotInfo.Alignment = file; } else if (file.Contains("_masshistogram")) { plotInfo.MassErrorHistogram = file; } else if (file.Contains("_nethistogram")) { plotInfo.NetErrorHistogram = file; } else if (file.Contains("_massmzresidual")) { plotInfo.MassMzResidual = file; } else if (file.Contains("_massscanresidual")) { plotInfo.MassScanResidual = file; } else if (file.Contains("_netresidual")) { plotInfo.NetResiduals = file; } } } info.PlotData = plotInfo; return plotInfo; }