Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
60
XamDataChart OlapXAxis and Accumulation Line
posted

Hi

I a have XamDataChart connected to a flat data source (i am using mvvm to bind the model to the data source)
the charts and the pivot grid works fine .
i am looking for a way to add Accumulation line to the chart ?
i added the following code

<ig:XamDataChart.Series>
     <ig:AccumulationDistributionIndicator NegativeBrush="Red"
 Brush="Green"
              Thickness="3"
              TrendLineBrush="DodgerBlue"
              TrendLineThickness="3"
              TrendLineType="ModifiedAverage"
              TrendLinePeriod="5"
              XAxis="{Binding ElementName=xmYAxis1, Mode=OneWay}"
              YAxis="{Binding ElementName=olapXAxis, Mode=OneWay}"
              ItemsSource="{Binding}"
              OpenMemberPath="Open"
              CloseMemberPath="Close"
              HighMemberPath="High"
              LowMemberPath="Low">
       </ig:AccumulationDistributionIndicator>
</ig:XamDataChart.Series>

it adds the line to the legend and not displaying the line .
is there away to achieve that and combine OlapXAxis with other Series like LineSeries ?

this is the markup for the chart.

<ig:XamDataChart MinHeight="500" 
        Legend="{Binding ElementName=xmLegend}"
        HorizontalAlignment="Stretch" 
        VerticalAlignment="Stretch"   
         x:Name="xmOlapDataChart"  
        VerticalZoombarVisibility="Visible" 
        VerticalZoomable="True"
        HorizontalZoombarVisibility="Visible"
        HorizontalZoomable="True">
     <ig:XamDataChart.Axes>
                <charts:OlapXAxis x:Name="olapXAxis"
                         DataSource="{Binding DataSource}"
                         OlapAxisSource="Columns"
                         DefaultSeries="ColumnSeries"   
                         YAxis="{Binding ElementName=xmYAxis1}"/>
                 <ig:NumericYAxis x:Name="xmYAxis1" MinimumValue="0" />
       </ig:XamDataChart.Axes>
   </ig:XamDataChart>

Thanks

Amir