System.out.println("minx,x,r = " + minx + ' ' + maxx + ' ' + xrange); System.out.println("miny,y,r = " + miny + ' ' + maxy + ' ' + yrange);
	public void read(String fname) {		LineNumberReader is = null;		try {			is = new LineNumberReader(new FileReader(fname));			String txt;			// Read the file a line at a time, parse it, save the data.			while ((txt = is.readLine()) != null) {				StringTokenizer st = new StringTokenizer(txt);				try {					Apoint d = new Apoint();					d.x = Float.parseFloat(st.nextToken());					d.y = Float.parseFloat(st.nextToken());					data.add(d);				} catch(NumberFormatException nfe) {					System.err.println("Invalid number on line " +						is.getLineNumber());				} // XXX catch out of range exception			}		} catch (FileNotFoundException e) {			System.err.println("File " + fname + " unreadable: " + e);		} catch (IOException e) {			System.err.println("I/O error on line " + is.getLineNumber());		}		n = data.size();		// find min & max        for (int i=0 ; i < n; i++) {			Apoint d = (Apoint)data.elementAt(i);			if (d.x < minx) minx = d.x;			if (d.x > maxx) maxx = d.x;			if (d.y < miny) miny = d.y;			if (d.y > maxy) maxy = d.y;        }		// Compute ranges		xrange = maxx - minx;		yrange = maxy - miny;	}