Dear R users,

i am using the following code to produce barcharts with lattice:

Compound<-c("Glutamine", "Arginine", "Glutamate", "Glycine", "Serine", 
"Glucose", "Fructose", "Raffinose",
"Glycerol", "Galacglycerol", "Threitol", "Galactinol", "Galactitol")


Class<-c("aminos","aminos","aminos","aminos","aminos","sugars","sugars","sugars","glycerols","glycerols","sugar 
alcohols","sugar alcohols","sugar alcohols")

set.seed(5)
Ratio<-rnorm(13, 0.5, 3)

df<-data.frame(Compound, Class,Ratio)

library(lattice)

P<-barchart(data=df,Ratio~Compound|Class)

However, I would like to have the bars attached to an imaginary y=0-line so 
that they go up if Ratio>0 and down if Ratio<0.
I saw some older entries in the mailing list supposing to use 
panel.barchart. However, I did not fully understand the usage of this 
function. Also, it was annouced to add an option to "barchart" to make it 
easier to get this type of plot.

Has anyone an idea what the easiest solution might be?

A second problem is concerning the display of the "Compound"-objects in 
accordance with the conditioning variable "Class". In other words: Is it 
possible to use the whole space of each panel for only those 
"Compound"-objects which belong to the "Class" displayed in that particular 
panel? Of course, for this purpose the panels have to be "detached" to 
allow appropiate labling of the x-axis.

Many thanks for your help,

Henning

    
-- 



	[[alternative HTML version deleted]]

