public MainWindow() { InitializeComponent(); this.DataContext = this; Sample1.Init(); Sample2.Init(plot, x, y, series); }