[Rd] histogram {lattice}: width of outmost bars

Wolfram Fischer wolfram at fischer-zim.ch
Thu Apr 3 13:11:59 MEST 2003


[R 1.6.1]

OBSERVATION

data( state )
histogram( ~ state.region
	, equal.widths = TRUE	# is not necessary with factors
	, scales = list( x = list( at = 1 : nlevels( state.region )
		, labels = as.character( levels( state.region ) )
		))
	)

The width of the bars touching the panel border
("Northeast" and "West") is not the same as the
width of the bars between these outmost bars.


PROPOSAL

All bars should have the same width.

I.e. the distance between the outmost tickmarks
to the panel border should be half the distance
between two neighbouring tickmarks.


Wolfram Fischer



More information about the R-devel mailing list