X軸でDataTime値のセットを使用したい。
achartengineを使用して、次のオブジェクトを表示したいと思います。
date1、
- 雨=>「値」
- 太陽=>「値」
- 風=>「値」
date2
- 雨=>「値」
- 太陽=>「値」
- 風=>「値」
等...
私はすでにそれらの値でachartengineを設定しました。
これが私のコードです:
if (mChartView == null){
layout_chart = (LinearLayout) findViewById(R.id.chart);
mChartView = ChartFactory.getCombinedXYChartView(
Grafico_modello.this
, chart.getDataset()//mDataset
, chart.getRenderer()//mRenderer
, chart.getTypes() //types
);
}
//populating the object on the .getDataset method
for (i=0;i<name_label.length;i++){
var[i] = new XYSeries(name_label[i]);
for (j=0;j<grafico.length();j++){
int unix_time=0;
unix_time=grafico.getDays()[j];
var[i].add(unix_time
, grafico.getVariabili()
.get(unix_time)
.get(name_var[i]));
}
}
更新1: