Jump to content
Software FX Community

Error when plotting an X bar / R chart with one series.


MJ27
 Share

Recommended Posts

Hi All,

I am trying to plot an X bar - R chart using only one series. I have changed the data in the example provided in ChartFx - Statistical Sample example found in the Chart Fx Resource Center.


The data now looks like this:

<?xml version="1.0"?>
<CHARTFX>
  <COLUMNS>
    <COLUMN NAME="Date" TYPE="String"/>
    <COLUMN NAME="Monday" TYPE="Double"/>
    <COLUMN NAME="Tuesday" TYPE="Double"/>
    <COLUMN NAME="Wednesday" TYPE="Double"/>
    <COLUMN NAME="Thursday" TYPE="Double"/>
    <COLUMN NAME="Friday" TYPE="Double"/>
  </COLUMNS>
  <ROW Date="2003-02-01" Monday="33"></ROW>
  <ROW Date="2003-02-08" Monday="30"></ROW>
  <ROW Date="2003-02-15" Monday="31.8"></ROW>
  <ROW Date="2003-02-22" Monday="28.5"></ROW>
  <ROW Date="2003-03-01" Monday="27.2"></ROW>
  <ROW Date="2003-03-08" Monday="30.5"></ROW>
  <ROW Date="2003-03-15" Monday="35.4"></ROW>
  <ROW Date="2003-03-22" Monday="33.6"></ROW>
  <ROW Date="2003-03-29" Monday="35.8"></ROW>
  <ROW Date="2003-04-05" Monday="30.4"></ROW>
  <ROW Date="2003-04-12" Monday="26.9"></ROW>
  <ROW Date="2003-04-19" Monday="28"></ROW>
  <ROW Date="2003-04-26" Monday="29.1"></ROW>
  <ROW Date="2003-05-03" Monday="26.4"></ROW>
  <ROW Date="2003-05-10" Monday="27.4"></ROW>
</CHARTFX>

 

I get the following error when I try running the X-chart or R-chart:

Index was out of range. Must be non-negative and less than the size of the collection.<br>Parameter name: index

Server Error in '/Statistical' Application.


Index was out of range. Must be non-negative and less than the size of
the collection.
Parameter name: index

Description:
An unhandled exception occurred during the execution of the current web
request. Please review the stack trace for more information about the error and
where it originated in the code.

Exception Details:
System.ArgumentOutOfRangeException: Index was out of range. Must be
non-negative and less than the size of the collection.
Parameter name:
index

Source Error:


Line 84:             ReadChartData("xChartData.txt",  true);Line 85:             Label1.Text = "The x Chart will only plot one point per configured data series. Each point displayed is actually the sample mean for all the observations (values) contained in the sample (series). Therefore, if you have 10 series of 50 points, your XChart will only display 10 values, the mean for each series.";Line 87:         }Line 88:         if (RadioButtonList1.SelectedValue == "r Chart")

Source
File:
c:\Program Files\Chart FX 7\Help and Samples\Sample Applications\Web
Forms\VS2008\Statistical\SPC.aspx.cs Line: 86

Stack
Trace:



[ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.Parameter name: index]   System.Collections.ArrayList.get_Item(Int32 index) +2880797   ChartFX.WebForms.Internal.RequiresAmbientCollection.get_Item(Int32 index) +30   ChartFX.WebForms.SeriesAttributesCollection.get_Item(Int32 index) +29   ChartFX.WebForms.Statistical.StudyInteractive.GetAxis(Int32 series) +152   ChartFX.WebForms.Statistical.StudyStripe.AttachToChart() +307   ChartFX.WebForms.Statistical.StudyStripe.b() +80   ChartFX.WebForms.Statistical.StudiesCollection.a() +187   ChartFX.WebForms.Statistical.Statistics.n() +77   ChartFX.WebForms.Statistical.SpcChart.a(Int32 A_0, Boolean A_1, Int32 A_2, IDualData A_3) +475   ChartFX.WebForms.GlobalAttributes.a(Gallery A_0, Int32 A_1, IGalleryType A_2, IGalleryTypeEx A_3, Boolean A_4) +296   ChartFX.WebForms.Chart.set_GalleryAttributes(Object value) +409   ChartFX.WebForms.Statistical.Galleries.a() +104   ChartFX.WebForms.Statistical.Galleries.set_Current(Gallery value) +29   SPC.RadioButtonList1_SelectedIndexChanged(Object sender, EventArgs e) in c:\Program Files\Chart FX 7\Help and Samples\Sample Applications\Web Forms\VS2008\Statistical\SPC.aspx.cs:86   System.Web.UI.WebControls.ListControl.OnSelectedIndexChanged(EventArgs e) +105   System.Web.UI.WebControls.RadioButtonList.RaisePostDataChangedEvent() +145   System.Web.UI.WebControls.RadioButtonList.System.Web.UI.IPostBackDataHandler.RaisePostDataChangedEvent() +7   System.Web.UI.Page.RaiseChangedEvents() +117   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1646




Version Information: Microsoft .NET Framework Version:2.0.50727.1433;
ASP.NET Version:2.0.50727.1433  

 

Does ChartFX implementation on X bar - Rchart allow such a scenario?

Could anybody please tell me what I am doing wrong.

 

I am using ChartFX 7

 

Thanks & Regards,

Melvin

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...