public void DateTimeXPlot() { var xyPair1 = new XyPair <DateTime, long>("AAAAA"); xyPair1.AddX(new DateTime(2018, 11, 20, 2, 0, 0)); xyPair1.AddX(new DateTime(2018, 11, 20, 4, 0, 0)); xyPair1.AddX(new DateTime(2018, 11, 20, 8, 0, 0)); xyPair1.AddY(18); xyPair1.AddY(32); xyPair1.AddY(21); xyPair1.HasScatter = true; IPythonProcess pythonProcess = new PythonProcess(PythonResources.GetPythonPath()); ITitle title = new Title("BBBBB", 32); IPlotColor colors = new PlotColor(); colors.OutsideColor = "#979899"; colors.InsideColor = "#d1d1d1"; IDesign <DateTime, long> design = new Design <DateTime, long>(title, colors, true, 16m, "▬", "CCCCC", "DDDDD"); ITickComposer <DateTime, long> tickComposer = new TickComposer <DateTime, long>(true, pythonProcess); IGeneralComposer <DateTime, long> composer = new GeneralComposer <DateTime, long>(pythonProcess, tickComposer); IPlotV3 <DateTime, long> plot = new PlotV3 <DateTime, long>(pythonProcess, design, composer); plot.AddSource(xyPair1); plot.Show(); }
public void DateXDLongYTest() { var xyPair1 = new XyPair <DateTime, long>("Some Legend A"); xyPair1.AddX(new DateTime(2018, 11, 20)); xyPair1.AddX(new DateTime(2018, 11, 21)); xyPair1.AddX(new DateTime(2018, 11, 22)); xyPair1.AddY(18); xyPair1.AddY(32); xyPair1.AddY(21); xyPair1.HasScatter = true; IPythonProcess pythonProcess = new PythonProcess(PythonResources.GetPythonPath()); ITitle title = new Title("This is a title", 32); IPlotColor colors = new PlotColor(); colors.OutsideColor = "#979899"; colors.InsideColor = "#d1d1d1"; IDesign <DateTime, long> design = new Design <DateTime, long>(title, colors, true, 16m, "▬", "aaa", "bbbb"); ITickComposer <DateTime, long> tickComposer = new TickComposer <DateTime, long>(false, pythonProcess); IGeneralComposer <DateTime, long> composer = new GeneralComposer <DateTime, long>(pythonProcess, tickComposer); IPlotV3 <DateTime, long> plot = new PlotV3 <DateTime, long>(pythonProcess, design, composer); plot.AddSource(xyPair1); plot.Show(); }
public void DateXDecimalYTest() { var xyPair1 = new XyPair <DateTime, decimal>("Some Legend A"); xyPair1.AddX(new DateTime(2018, 11, 20)); xyPair1.AddX(new DateTime(2018, 11, 21)); xyPair1.AddX(new DateTime(2018, 11, 22)); xyPair1.AddY(0.18m); xyPair1.AddY(0.32m); xyPair1.AddY(0.21m); xyPair1.HasScatter = true; IPythonProcess pythonProcess = new PythonProcess(PythonResources.GetPythonPath()); ITitle title = new Title("This is a title", 16); IPlotColor colors = new PlotColor(); colors.OutsideColor = "#979899"; colors.InsideColor = "#d1d1d1"; IDesign <DateTime, decimal> design = new Design <DateTime, decimal>(title, colors, true, 0.5m, "&", "cccc", "dddd"); ITickComposer <DateTime, decimal> tickComposer = new TickComposer <DateTime, decimal>(false, pythonProcess); IGeneralComposer <DateTime, decimal> composer = new GeneralComposer <DateTime, decimal>(pythonProcess, tickComposer); IPlotV3 <DateTime, decimal> plot = new PlotV3 <DateTime, decimal>(pythonProcess, design, composer); plot.AddSource(xyPair1); plot.Show(); }