本文整理了Java中com.github.mikephil.charting.components.YAxis.setAxisMaximum()
方法的一些代码示例,展示了YAxis.setAxisMaximum()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YAxis.setAxisMaximum()
方法的具体详情如下:
包路径:com.github.mikephil.charting.components.YAxis
类名称:YAxis
方法名:setAxisMaximum
暂无
代码示例来源:origin: PhilJay/MPAndroidChart
leftAxis.setAxisMaximum(1.2f);
leftAxis.setAxisMinimum(-1.2f);
代码示例来源:origin: PhilJay/MPAndroidChart
chart.getAxisRight().setAxisMaximum(25f);
chart.getAxisRight().setAxisMinimum(-25f);
chart.getAxisRight().setDrawGridLines(false);
代码示例来源:origin: PhilJay/MPAndroidChart
leftAxis.setGranularityEnabled(true);
leftAxis.setAxisMinimum(0f);
leftAxis.setAxisMaximum(170f);
leftAxis.setYOffset(-9f);
leftAxis.setTextColor(Color.rgb(255, 192, 56));
代码示例来源:origin: PhilJay/MPAndroidChart
leftAxis.setLabelCount(6, false);
leftAxis.setAxisMinimum(-2.5f);
leftAxis.setAxisMaximum(2.5f);
leftAxis.setGranularityEnabled(true);
leftAxis.setGranularity(0.1f);
rightAxis.setLabelCount(6, false);
rightAxis.setAxisMinimum(-2.5f);
rightAxis.setAxisMaximum(2.5f);
rightAxis.setGranularity(0.1f);
代码示例来源:origin: PhilJay/MPAndroidChart
leftAxis.setTypeface(tfLight);
leftAxis.setTextColor(ColorTemplate.getHoloBlue());
leftAxis.setAxisMaximum(200f);
leftAxis.setAxisMinimum(0f);
leftAxis.setDrawGridLines(true);
rightAxis.setTypeface(tfLight);
rightAxis.setTextColor(Color.RED);
rightAxis.setAxisMaximum(900);
rightAxis.setAxisMinimum(-200);
rightAxis.setDrawGridLines(false);
代码示例来源:origin: PhilJay/MPAndroidChart
leftAxis.setAxisMaximum(900f);
leftAxis.setAxisMinimum(-250f);
leftAxis.setDrawAxisLine(false);
代码示例来源:origin: PhilJay/MPAndroidChart
yAxis.setAxisMaximum(200f);
yAxis.setAxisMinimum(-50f);
代码示例来源:origin: PhilJay/MPAndroidChart
yAxis.setTextSize(9f);
yAxis.setAxisMinimum(0f);
yAxis.setAxisMaximum(80f);
yAxis.setDrawLabels(false);
代码示例来源:origin: PhilJay/MPAndroidChart
leftAxis.setTypeface(tfLight);
leftAxis.setTextColor(Color.WHITE);
leftAxis.setAxisMaximum(100f);
leftAxis.setAxisMinimum(0f);
leftAxis.setDrawGridLines(true);
代码示例来源:origin: fossasia/pslab-android
public void setRightYAxisScale(double upperLimit, double lowerLimit) {
y2.setAxisMaximum((float) upperLimit);
y2.setAxisMinimum((float) lowerLimit);
if (upperLimit == 500f)
rightYAxisLabelUnit.setText("(mV)");
else
rightYAxisLabelUnit.setText("(V)");
mChart.fitScreen();
mChart.invalidate();
}
代码示例来源:origin: fossasia/pslab-android
public void setLeftYAxisScale(double upperLimit, double lowerLimit) {
y1.setAxisMaximum((float) upperLimit);
y1.setAxisMinimum((float) lowerLimit);
if (upperLimit == 500f)
leftYAxisLabelUnit.setText("(mV)");
else
leftYAxisLabelUnit.setText("(V)");
mChart.fitScreen();
mChart.invalidate();
}
代码示例来源:origin: fossasia/pslab-android
statMin.setText(String.valueOf(baroValue));
y.setAxisMaximum(currentMax);
y.setAxisMinimum(currentMin);
y.setLabelCount(10);
代码示例来源:origin: fossasia/pslab-android
statMin.setText(String.valueOf(luxValue));
y.setAxisMaximum(currentMax);
y.setAxisMinimum(currentMin);
y.setLabelCount(10);
代码示例来源:origin: fossasia/pslab-android
sum += entry.getY();
y.setAxisMaximum(currentMax);
y.setAxisMinimum(currentMin);
y.setLabelCount(10);
代码示例来源:origin: fossasia/pslab-android
sum += entry.getY();
y.setAxisMaximum(currentMax);
y.setAxisMinimum(currentMin);
y.setLabelCount(10);
代码示例来源:origin: fossasia/pslab-android
y.setAxisMaximum(10f);
y.setAxisMinimum(-10f);
y.setDrawGridLines(true);
代码示例来源:origin: fossasia/pslab-android
y.setAxisMaximum(6.15f);
y.setAxisMinimum(-6.15f);
y.setDrawGridLines(true);
代码示例来源:origin: fossasia/pslab-android
public void chartInit() {
mChart.setTouchEnabled(true);
mChart.setHighlightPerDragEnabled(true);
mChart.setDragEnabled(true);
mChart.setScaleEnabled(true);
mChart.setDrawGridBackground(false);
mChart.setPinchZoom(true);
mChart.setScaleYEnabled(false);
mChart.setBackgroundColor(Color.BLACK);
mChart.getDescription().setEnabled(false);
LineData data = new LineData();
data.setValueTextColor(Color.WHITE);
mChart.setData(data);
Legend l = mChart.getLegend();
l.setForm(Legend.LegendForm.LINE);
l.setTextColor(Color.WHITE);
x1.setTextColor(Color.WHITE);
x1.setDrawGridLines(true);
x1.setAvoidFirstLastClipping(true);
x1.setAxisMinimum(0f);
x1.setAxisMaximum(875f);
y1.setTextColor(Color.WHITE);
y1.setAxisMaximum(16f);
y1.setAxisMinimum(-16f);
y1.setDrawGridLines(true);
y2.setAxisMaximum(16f);
y2.setAxisMinimum(-16f);
y2.setTextColor(Color.WHITE);
y2.setEnabled(true);
}
代码示例来源:origin: fossasia/pslab-android
private void setupInstruments() {
lightMeter.setMaxSpeed(PreferenceManager.getDefaultSharedPreferences(getActivity()).getFloat(luxSensor.LUXMETER_LIMIT, 10000));
XAxis x = mChart.getXAxis();
this.y = mChart.getAxisLeft();
YAxis y2 = mChart.getAxisRight();
mChart.setTouchEnabled(true);
mChart.setHighlightPerDragEnabled(true);
mChart.setDragEnabled(true);
mChart.setScaleEnabled(true);
mChart.setDrawGridBackground(false);
mChart.setPinchZoom(true);
mChart.setScaleYEnabled(true);
mChart.setBackgroundColor(Color.BLACK);
mChart.getDescription().setEnabled(false);
LineData data = new LineData();
mChart.setData(data);
Legend l = mChart.getLegend();
l.setForm(Legend.LegendForm.LINE);
l.setTextColor(Color.WHITE);
x.setTextColor(Color.WHITE);
x.setDrawGridLines(true);
x.setAvoidFirstLastClipping(true);
y.setTextColor(Color.WHITE);
y.setAxisMaximum(currentMax);
y.setAxisMinimum(currentMin);
y.setDrawGridLines(true);
y.setLabelCount(10);
y2.setDrawGridLines(false);
}
代码示例来源:origin: fossasia/pslab-android
private void setupInstruments() {
baroMeter.setMaxSpeed(PreferenceManager.getDefaultSharedPreferences(getActivity()).getFloat(baroSensor.BAROMETER_LIMIT, 2));
XAxis x = mChart.getXAxis();
this.y = mChart.getAxisLeft();
YAxis y2 = mChart.getAxisRight();
mChart.setTouchEnabled(true);
mChart.setHighlightPerDragEnabled(true);
mChart.setDragEnabled(true);
mChart.setScaleEnabled(true);
mChart.setDrawGridBackground(false);
mChart.setPinchZoom(true);
mChart.setScaleYEnabled(true);
mChart.setBackgroundColor(Color.BLACK);
mChart.getDescription().setEnabled(false);
LineData data = new LineData();
mChart.setData(data);
Legend l = mChart.getLegend();
l.setForm(Legend.LegendForm.LINE);
l.setTextColor(Color.WHITE);
x.setTextColor(Color.WHITE);
x.setDrawGridLines(true);
x.setAvoidFirstLastClipping(true);
y.setTextColor(Color.WHITE);
y.setAxisMaximum(currentMax);
y.setAxisMinimum(currentMin);
y.setDrawGridLines(true);
y.setLabelCount(10);
y2.setDrawGridLines(false);
y2.setMaxWidth(0);
}
内容来源于网络,如有侵权,请联系作者删除!