Jump to content
Software FX Community

krb875

Members
  • Posts

    30
  • Joined

  • Last visited

krb875's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. I just need to highlight one of the points on the line. The source is a simple Array of Singles containing about 280 elements. How to I highlight the X point on the line in c#. I appreciate the work JuanC. just incase you want to see whats going on I've attached the following ChartFX.WPF.SeriesAttributes series1 = new ChartFX.WPF.SeriesAttributes();ChartFX.WPF.SeriesAttributes series2 = new ChartFX.WPF.SeriesAttributes(); series1.ItemsSource = m_smartBus1[region].VLOADARRAY; series2.ItemsSource = m_smartBus2[region].VLOADARRAY; series1.Gallery = ChartFX.WPF.Gallery.Line; series2.Gallery = ChartFX.WPF. Gallery.Line;series1.Fill = System.Windows.Media.Brushes.Blue; series2.Fill = System.Windows.Media. Brushes.OrangeRed;series1.Content = "Vload vs Ref Curve 1st Dir"; series2.Content = "Vload vs Ref Curve 2nd Dir";series1.PointLabels.Visibility = System.Windows.Visibility.Hidden; series2.PointLabels.Visibility = System.Windows. Visibility.Hidden; chartfxVloadVsRef0 = new ChartFX.WPF.Chart(); vloadvsRefElemHost0.Child = chartfxVloadVsRef0; chartfxVloadVsRef0.AxisY = new ChartFX.WPF.Axis();chartfxVloadVsRef0.AxisY.ForceZero = false; chartfxVloadVsRef0.Series.Add(series1); chartfxVloadVsRef0.Series.Add(series2);
  2. Hopefully this is a simple question, If I have a line graph and I want to mark a particular point on that graph with a marker and I have the corresponding value to is there away to do this without having to overlay a scatterplot on top of the line plot.
  3. Thanks alot, this works I had a problem with my reference! I appreciate all the help
  4. The following is my XYMeasure code, but when I call add XYMeasure() it seems to put the point at 0,0 anyways. using System;using System.Collections.Generic;using System.Linq;using System.Text;using ChartFX.WPF;namespace IRTECH.ModCal.FileIO { public class XYMeasure{ private Nullable<double> m_x; private Nullable<double> m_y;public XYMeasure() { m_x = null;m_y = null; } public XYMeasure(Nullable<double> x, Nullable<double> y) { m_x = x; m_y = y; } public Nullable<double> X { get { return m_x; }set { m_x = value; } } public Nullable<double> Y { get { return m_y; }set { m_y = value; } } } }
  5. JuanC, I got the latest build 3097, how do I set the double's to nullabe so they will be a hidden value?
  6. Also i got the latest hotfix and cant get this to work I made blank constructor in my XYMeasure class that does not set the values to anything but by default it is set to 0,0, and it places all the points there.
  7. I explored this way to do it the problem is that I will be calling each of these functions over 5 times each, meaning i have to seperate and create a seperate XYMeasure and a sepereate series for each, instead of doing it as I was earlier. I can def do it this way it just will be a mess. This might not seem like such a bad thing for the example you have shown but when My temp refs plot has 7 lines over 6 regions (42 series calls) it makes the code hugely wasteful. I think the best way would be to have some sort of option that if you set your Content to the same name on a chart. like series1.content = "Hot"; series2.content="hot" have a way to toggle whetehr or not you want the chart to combine these into one series rather than keeping them seperate, but inserting a blank datapoint between each existing series.
  8. That works great! no my main problem is the legend box, how can i in c# determine which series it adds to the legend box. I would like a method that would check series.content and if they are the same combine them into one series on the legend, or something like that. Or any other ideas how to get this accomplished
  9. I still have not been able to get the legend to edit out the extra series or to display itself over the graph instead of on the side. Did anything with the new release help here? Thanks
  10. JuanC, did you have any ideas of how to get this accomplished?
  11. Im actually using this as a COM object to display data from a VB6 project, as well as future other .NET projects. I am just reprocessing the data based on the input. The user is actually calling this function for each seperate "series" even if they are technically the same data. The reason for this is we are processing multiple regions of a camera and collecting that data. As you can see I am just seperating every other line as Hot and then Cold Data. There is an overlap between the regions which is why at the interval the points overlap. I would like to keep this struction because it is not set how many data points each region contains so this gives us flexibility to support many different camera types and other applications, If i use a "hidden" variable I think it will be hard to maintain this, and I am assuming I would have to pass in all the data in one long gather. public void plotResponsePlots(double[][] value, int step, int start) { for (int k = 0; k < value.Length; k++) { this.m_Report.axes_resp.ItemsSource = null; double location = start;ChartFX.WPF.SeriesAttributes series = new ChartFX.WPF.SeriesAttributes(); List<XYMeasure> dataPts = new List<XYMeasure>();for (int i = 0; i < value[k].Length; i++) { dataPts.Add(new XYMeasure(location, value[k]));if (i < value[k].Length - 1) { location += step; } } if (k % 2 == 0) { series.Fill = System.Windows.Media.Brushes.Red;series.Content = "Hot"; } else { series.Fill = System.Windows.Media.Brushes.Blue;series.Content = "Cold"; } series.ItemsSource = dataPts; series.BindingPath = "Y"; series.BindingPathX = "X";series.Marker.Shape = ChartFX.WPF.MarkerShape.Circle;this.m_Report.axes_resp.Series.Add(series); } } Also before I forget, is there a way to inlay the legend box on the graph instead of to the side so that the graph points going behind the legend. Kinda like this: (this is the matlab code i am replacing) http://img.photobucket.com/albums/v667/krb875/MHTWS_0011153_Summary.jpg
  12. I was told when I emailed them that late june to mid july would be a go-live release with a full production release probably in august or sept.
  13. I have a multi series graph that actually uses multiple series to show the same graph because of discontinuities in the line. Here is a link to the print out I am currently generating so you have an idea of what I mean http://img.photobucket.com/albums/v667/krb875/Summary.jpg?t=1213914483 I need to create a legend box that is ontop of the current graph with a clear background so that I can maximize space. Here is the problem, for instance the botton left graph has two red and two blue lines, but I only want 2 entries in the legend box. I know I can set what shows up in the box with the series.content command. I am using C# to generate this graph so I would prefer to stick with that if at all possible. I can create a legendbox right now but it is off to the side and contains two hot and two cold items. Also a stretch, but is there anyone to link the plots together so that when one is highlighted in the legend box it would show all the Hot or Cold data. thanks for all the help, cant wait for the release!
  14. krb875

    dotted line

    How do you make a line graph be dotted between the points?
  15. I got the Marker Shape to work but I cannot change the color of the seires. is it series.fill = Color.Red for instance; cause when i try this it says cannot convert System.Drawing.Color to System.Windows.Media.Brush
×
×
  • Create New...