示例#1
0
        private static void Main(string[] args)
        {
            ScottPlot2.ScottPlot SP    = new ScottPlot2.ScottPlot();
            ScottPlot2.Generate  SPgen = new ScottPlot2.Generate();

            SP.SetSize(1500, 400);
            SP.AddLine(SPgen.Sequence(5000), SPgen.Sine(5000));

            SP.Render();
            SP.SaveFig("test.jpg");
        }
示例#2
0
 // call to REPLOT the figure (i.e., after a view or axis change)
 public void GraphDraw()
 {
     if (SP.dataSizeX == 0)
     {
         GraphResize();
     }
     SP.stopwatch.Restart();                    // start the stopwatch
     SP.ClearData();                            // clear the graph entirely
     SP.DrawGrid();                             // make a line grid
     SP.AddLine(Xs, Ys);                        // plot the points stored in Xs and Ys
     pictureBox1.BackgroundImage = SP.Render(); // render the axis+graph
     this.Refresh();                            // force the window to redraw
     richTextBox1.Text = SP.Info();             // update the textbox info
 }