Auto fit labels in R boxplot -


We currently use R for generating various types of boxplots / Code>.

We have the problem that the length of our plots varies considerably between different plots and sections in a plot.

Is there a way to automatically adjust a plot so that all the labels fit it well?

It is not possible to specify the worst case mar because the label in some plots is much less than the other.

is a Latys graphics library which is likely to be helpful here. I say that for two reasons: (i) Latis is based on grid system, and by reaching the grid's graphical premiums, you can get more control in place of the other things, instead of your panel output; And (ii) There's more to work with - R standard graphics package has 70 different parameters, while there are 371 in the laties - from my count, (length (name (list (list (tarry. .) ()))), Yet they are not in the 371 flat structure as they are in the original package, but instead in the hierarchical structure (with parameter groups at 30 level or higher level) is collected.

What do you want the relative position of your axis label I would recommend going down one level for this type of work, then what you want to do, just replace related grid slots, then two greebs Redraw (using R interactive prompts):

  Library (Latin) library (grid) bwplot (~ runif 200, 10, 99), xlab = "x-axis label", ylab = "Y-axis label") #x-axis labels left grid Edit (take "[.] Xlab $", grep = T, X = unit (0, "NPC"), bus = "left", redraw = t) # to the right grid. Edit (insert "[.] Xlab $", grep = T, x = unit (1, "NPC"), bus = "right", redraw = T) # into the center grid.edit ("[.] Xlab $ ", Grep = T, x = unit (0.5," NPC "), Y-axis grid.edit (" [.] Ylab $ ", grep = T, y = for unit (0.5," NPC ") = "Center", for redraw only # = "center", redraw = T) = t)  

"[.] .xlab $", grid.edit takes a gPath object (Only one path which is a great, which is only in the second gross); Because I did not know that the object of my interest in the gpath (X-axis / Y-axis label, I use a regular expression form for the object;

"grep = T", just the last To keep the parameter as regular expression, the grid.itits;

"X = unit (0.5, 'NPC)", specifies the viewport coordinates (in this case, just x values); 'NPC' ('Generalized Basic Coordinator', which is defined as Diff Is the default) viewport originates as root (0,0), and it gives the width and height of an entity, so I have the center of the viewport X axis.


Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

jquery - SimpleModal Confirm fails to submit form -

php - Multiple Select with Explode: only returns the word "Array" -