Page 1 of 1

EquiVolume conversion

Posted: Tue Mar 29, 2016 10:45 am
by 16071129
I am converting existing candle series to EquiVolume and adding volumes from existing volume series.
Conversion is successful but EquiVolume series is not visible when I check data of it volume values are zero values.
My existing candle series and volume series both are having data.
I am using following code

Code: Select all

                        Series candleSeries = tChart1.Series[0];
                        Series.ChangeType(ref candleSeries, typeof(Steema.TeeChart.Styles.EquiVolume));
                        EquiVolume eqVol = (EquiVolume)candleSeries;
                        eqVol.VolumeValues = volumeSeries.YValues;

Re: EquiVolume conversion

Posted: Tue Mar 29, 2016 11:14 am
by 16071129
I didn't find any code related to EquiVolume in TeeChart Samples.
But my problem is solved with

Code: Select all

    eqVol.VolumeValues.Value = volumeSeries.YValues.Value; 


New problem arises after conversion of series to EquiVolume. Chart Control slows down after conversion of candle to EquiVolume.

Re: EquiVolume conversion

Posted: Wed Mar 30, 2016 12:02 pm
by Christopher
Quant wrote:New problem arises after conversion of series to EquiVolume. Chart Control slows down after conversion of candle to EquiVolume.
Using test code similar to the following:

Code: Select all

    TChart tChart1;
    private void InitializeChart()
    {
      Utils.CalcFramesPerSecond = true;
      tChart1 = new TChart();
      tChart1.Dock = DockStyle.Fill;
      tChart1.Aspect.View3D = false;
      tChart1.Series.Add(typeof(EquiVolume)).FillSampleValues(50);
    }

    private void button4_Click(object sender, EventArgs e)
    {
      timer.Interval = 10;
      timer.Tick += Timer_Tick;
      timer.Start();
    }

    private void Timer_Tick(object sender, EventArgs e)
    {
      tChart1[0].FillSampleValues(50);
      this.Text = Utils.FramesPerSecond.ToString();
    }
no significant difference in FPS can be detected between Candle and EquiVolume series. Can you please send us some code which clearly shows the slowing down you speak of?