private void addLineToData() {
            if (data.getLineChartData().getLines().size() >= maxNumberOfLines) {
                Toast.makeText(getActivity(), "Samples app uses max 4 lines!", Toast.LENGTH_SHORT).show();
                return;
            } else {
                ++numberOfLines;
            }

            generateData();
        }
A fragment containing a combo line/column chart view.
hellocharts-samples/src/lecho/lib/hellocharts/samples/ComboLineColumnChartActivity.java