Android 未显示ACE值

Android 未显示ACE值,android,achartengine,Android,Achartengine,使用achartengine,我需要在时间图表上显示值。根据我放置命令行的位置,不会显示任何值或错误的值。我想这是因为列表在库中的使用方式(排序),但我不知道如何处理 代码如下: public GraphicalView getViewTime(Context context, int spinnerSelection, List<myObject> myDataSrc) { // ********************* // SET Graphical obj

使用achartengine,我需要在时间图表上显示值。根据我放置命令行的位置,不会显示任何值或错误的值。我想这是因为列表在库中的使用方式(排序),但我不知道如何处理

代码如下:

public GraphicalView getViewTime(Context context, int spinnerSelection, List<myObject> myDataSrc) {

    // *********************
    // SET Graphical objects
    // *********************
    XYMultipleSeriesRenderer mRenderer = new XYMultipleSeriesRenderer();
    XYMultipleSeriesDataset mDataSet = new XYMultipleSeriesDataset();

    // **************
    // AUTOSCALING
    // **************
    AutoScaling<E> AutoScaled = new AutoScaling<E>(spinnerSelection, myDataSrc);

    // *************
    // mdataset
    // *************
    List<Date[]> X_serie = AutoScaled.getXserie();
    List<double[]> Y_serie = AutoScaled.getYserie();

    String[] titles = new String[] { ""/* spinnerSelection */};
    mDataSet = buildDateDataset(titles, X_serie, Y_serie);


    // **************
    // mRenderers
    // **************
    // LEGENDS
    String ChartTitle = getTitle(context, spinnerSelection);
    //mRenderer.setDisplayChartValues(true);

    setChartSettings(mRenderer, ChartTitle, XlegendText, YlegendText, AutoScaled.getFirstRecordDate(), AutoScaled.getLastRecordDate(), 0.0, AutoScaled.getYmax(),
                Color.GRAY, Color.LTGRAY);

    // if command line is here, no values are shown
    // mRenderer.setDisplayChartValues(true);

    // LABELS
    mRenderer.setYLabels(YlabelsCount);
    mRenderer.setXLabels(XlabelsCount);
    mRenderer.setShowLabels(true);
    mRenderer.setXLabelsAlign(Align.RIGHT);
    // renderer.setXLabelsAngle(270L);
    mRenderer.setYLabelsAlign(Align.RIGHT);

    // COLORS
    int[] Colors = new int[] { curveColors[spinnerSelection] };
    mRenderer = buildRenderer(Colors, styles);

     // Shows values at the wrong "place", like random because of List I guess
    // mRenderer.setDisplayChartValues(true);

    // ZOOM
    double[] panLimits = AutoScaled.getPanLimits();
    mRenderer.setZoomEnabled(XenabledZoom, YenabledZoom);
    mRenderer.setZoomButtonsVisible(showZoomButtons);
    mRenderer.setZoomRate(ZoomRate);
    mRenderer.setPanLimits(panLimits);
    mRenderer.setZoomLimits(panLimits);

    // SHOW ONLY last WEEK even after Zoom reset
    mRenderer.setXAxisMin( AutoScaled.getDateOneWeekAgo() );
    mRenderer.setInitialRange(AutoScaled.getXYRange());

    // GRID
    mRenderer.setShowGrid(showGrid);

    // VIEW
    GraphicalView BasicView = ChartFactory.getTimeChartView(context, mDataSet, mRenderer, DateFormat);

    return BasicView;
}

几乎帮不上忙。什么是自动缩放,自动缩放,E…?@Dan:Thx-Dan,很难删除数百行代码。如果需要或有用,我可以转储X_serie和Y_serie的一部分?只要试着发布一段复制问题的代码,我就可以进行测试。@Dan:我已经输入了我使用的值,因为发布现有代码就像地狱一样,或者我必须用它们的真实值来替换数据。我建议你只需要编写一段代码,用一些硬编码的值来复制这个问题。我需要运行这段代码才能弄清楚到底发生了什么。如果我很难帮助你解决阿卡廷发动机的问题,那么没有人能帮助你。相信我。
int XlabelsCount = 7;
int YlabelsCount = 10;
float ZoomRate = 1.20f;
String DateFormat = "dd MMM yy\n HH:mm";

11-16 15:46:34.935: I/TwoAxisVsTime(2316): LIST DUMP X_serie (94 datas in total): 
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=0 =>Thu Oct 25 20:16:06 UTC+02:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=1 =>Sun Oct 28 10:53:41 UTC+01:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=2 =>Wed Nov 07 13:06:43 UTC+01:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=3 =>Wed Sep 26 16:42:39 UTC+02:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=4 =>Sun Sep 30 16:49:00 UTC+02:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=5 =>Mon Oct 29 12:14:59 UTC+01:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=6 =>Sun Oct 28 14:54:21 UTC+01:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=7 =>Thu Nov 01 20:24:32 UTC+01:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=8 =>Sat Oct 27 20:22:26 UTC+02:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=9 =>Wed Nov 14 15:16:10 UTC+01:00 2012,
11-16 15:46:34.935: I/TwoAxisVsTime(2316): i=10 =>Wed Nov 14 12:04:38 UTC+01:00 2012,

11-16 15:46:34.945: I/TwoAxisVsTime(2316): DUMP Y_serie (94 datas in total): 
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 152.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 81.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 178.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 120.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 89.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 329.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 63.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 68.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 85.0,
11-16 15:46:34.945: I/TwoAxisVsTime(2316): 252.0,

11-16 15:46:34.965: I/TwoAxisVsTime(2316): _________________
11-16 15:46:34.965: I/TwoAxisVsTime(2316): getFirstRecordDate
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 1.34747055E12
11-16 15:46:34.965: I/TwoAxisVsTime(2316): _________________
11-16 15:46:34.965: I/TwoAxisVsTime(2316): getLastRecordDate
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 1.35304991E12
11-16 15:46:34.965: I/TwoAxisVsTime(2316): ____________________
11-16 15:46:34.965: I/TwoAxisVsTime(2316): AutoScaled.getYmax()
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 442.0
11-16 15:46:34.965: I/TwoAxisVsTime(2316): ___________
11-16 15:46:34.965: I/TwoAxisVsTime(2316): panLimits
11-16 15:46:34.965: I/TwoAxisVsTime(2316): ARRAY DUMP : 
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 1.34747055E12,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 1.35304991E12,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 0.0,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 442.0,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): _______________________
11-16 15:46:34.965: I/TwoAxisVsTime(2316): AutoScaled.getXYRange()
11-16 15:46:34.965: I/TwoAxisVsTime(2316): ARRAY DUMP : 
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 1.35244511E12,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 1.35304991E12,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 0.0,
11-16 15:46:34.965: I/TwoAxisVsTime(2316): 442.0,