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
380
Error Bars and Y Axis scalling
posted

I have a scatterseries chart bound to a items collection.  We calculate our own errors, so for errorbars I set the verticalCalculator to the DataCalculator and set the correct items source and ValueMemberPath.  This all seems to work correctly when I toggle the errors they show up with the correct values.  

The problem that the y Axis does not change its scale to account for the top of the error bar, so I end up with clipping.  How do I get the yAxis to update when I turn on the error bars?

        private void AddErrorBars(ScatterSeries scatterSeries)
        {
            var errorBarSettings = new ScatterErrorBarSettings
                                       {
                                           EnableErrorBarsHorizontal = EnableErrorBars.None,
                                           EnableErrorBarsVertical = ShowY1ErrorBars ? EnableErrorBars.Both : EnableErrorBars.None,
                                           HorizontalErrorBarCapLength = 10,
                                           HorizontalStroke = scatterSeries.Brush,
                                           HorizontalStrokeThickness = 2,
                                           VerticalStroke = scatterSeries.Brush,
                                           VerticalErrorBarCapLength = 10,
                                           VerticalStrokeThickness = 2,
                                           VerticalCalculator = new DataCalculator
                                                                    {
                                                                        ItemsSource = scatterSeries.ItemsSource,
                                                                        ValueMemberPath = "DataError2"
                                                                    },
                                       };
            scatterSeries.ErrorBarSettings = errorBarSettings;
        }
  • 138253
    Offline posted

    Hello,

     

    I am just checking if you got this worked out or you still require any assistance or clarification on the matter.  

  • 138253
    Offline posted

    Hello,

     

    Thank you for your post. I have been looking into it, but since this is not a known issue I cannot be completely sure what can cause this behavior, so could you please send an isolated sample project, where the issue is reproduced, so I can investigate it further for you.

     

    Looking forward for your reply.