Displaying 20 results from an estimated 7000 matches similar to: "Rotating margin text"
2018 Mar 30
3
getting all circular arrangements without accounting for order
Dear friends,
I would like to get all possible arrangements of n objects listed 1:n on a circle.
Now this is easy to do in R. Keep the last spot fixed at n and fill in the rest using permuations(n-1, n-1) from the gtools package.
However, what if clockwise or counterclockwise arrangements are the same? I know that half of the above (n - 1)! arrangements are redundant.
Is there an easy way to
2010 Mar 27
1
string width calculation
Colleagues,
I am trying to create a PDF document in which I use margin text with two different fonts. The resulting text might be:
XXXXXyZZZ
where X and Z are one font and Y is the other.
My plan was to do this in the following manner:
mtext("XXXXX ZZZ", cex=2, adj=0.5, family=SOMEFONT)
mtext("Y", cex=2, adj=??, family=DIFFERENTFONT)
My question regards how to calculate
2010 Aug 01
3
Constructing arguments for plotmath
Colleagues,
I am encountering difficulty adding formatted text to a graphic. Specifically, I want to add a superscript in the middle of a text string but I would like to format the text string on the fly. The commands:
plot(1,1)
ARG <- bquote('TEXT'^'\u00ae')
mtext(ARG, line=-2, side=1)
yield the desired output.
However, my goal is to paste together a string, then pass
2006 Feb 08
2
rotating axis / mtext labels
Hello list.
Is it possible to use par(srt=45) to rotate text by 45 degrees along the
x-axis of a plot. Using:
<code>
x_names<-c("C57 Nv", "C57 Vacc", "129 Nv", "129 Vacc", "IFNgR Nv", "IFNgR Vacc")
par(srt=45)
mtext(font=2, x_names, side=1, line=1, at=l, cex=1.2)
par(srt=0)
</code>
doesn't seem to work in R 2.2.0
2012 Sep 02
2
Impact of cex changing as a function of mfrow
R 2.15.1
OS X (MLion)
Colleagues,
I am aware that changes in mfrow / mfcol in par() affect cex (from help: In a layout with exactly two rows and columns the base value of ?"cex"? is reduced by a factor of 0.83: if there are three or more of either rows or columns, the reduction factor is 0.66).
I generate a multipage PDF in which mfrow varies such that cex is impacted. This affect
2010 Jan 23
1
Failure to produce italics in jpeg
Colleagues,
Using R 2.10.1 in OS X (Snow Leopard), I created JPEG documents that
were intended to include italicized text. In the JPEG versions, the
italics appear in bold-face. The identical code (except for the call
to the device) yields italics in PDF. A minimal example is:
PDF version:
> pdf("plot.pdf")
> plot(1,1)
> mtext(bquote(italic(P) < .(0.005)))
>
2010 Jul 20
1
Registered / trademark signs
Colleagues,
What is the easiest means to embed a:
? (registered)
or
? (trademark)
sign in text in a graphic. I would like to use mtext and avoid plotmath, if possible. Ideally, the sign should be superscripted but I can easily sacrifice that.
Optimally, I need a solution that works in both OS X and Windows (? XP) and with R versions ? 2.11
Thanks in advance.
Dennis
Dennis Fisher MD
P <
2018 Mar 30
0
getting all circular arrangements without accounting for order
If one is equal to the reverse of another, keep only one of the pair.
B.
> On Mar 29, 2018, at 9:48 PM, Ranjan Maitra <maitra at email.com> wrote:
>
> Dear friends,
>
> I would like to get all possible arrangements of n objects listed 1:n on a circle.
>
> Now this is easy to do in R. Keep the last spot fixed at n and fill in the rest using permuations(n-1, n-1)
2023 Jun 08
2
need help with plotmath and/or plotting unicode characters
R 4.2.3
OS X
Colleagues
This should be easy -- but not for me.
I want to plot text similar to this:
N ? XX: YY
where XX can be either 1 or 50 and YY is an integer
I envision that there would be two solutions:
UNICODE: If I can generate "?" via unicode, the problem is solved:
mtext(side=3, paste0("N ", UNICODE, " ", XX, ": ", YY))
PLOTMATH:
2023 Jan 16
3
Printing special characters
R 4.2.2
OS X
Colleagues
A file that I have read includes strings like this:
"EVENT ? 30 sec"
When I include the string in a graphic using:
mtext(STRING, ?)
it appears as:
"EVENT ... 30 sec"
Is there a simple work-around (short of reformatting all the strings, then using plotmath)?
Dennis
Dennis Fisher MD
P < (The "P Less Than" Company)
Phone / Fax:
2023 Jan 16
1
Printing special characters
Use the Cairo PDF device?
On January 16, 2023 12:18:48 AM PST, Dennis Fisher <fisher at plessthan.com> wrote:
>R 4.2.2
>OS X
>
>Colleagues
>
>A file that I have read includes strings like this:
> "EVENT ? 30 sec"
>When I include the string in a graphic using:
> mtext(STRING, ?)
>it appears as:
> "EVENT ... 30 sec"
>
>Is there a
2018 Mar 30
3
getting all circular arrangements without accounting for order
Thanks!
Yes, however, this seems a bit wasteful. Just wondering if there are other, more efficient options possible.
Best wishes,
Ranjan
On Thu, 29 Mar 2018 22:20:19 -0400 Boris Steipe <boris.steipe at utoronto.ca> wrote:
> If one is equal to the reverse of another, keep only one of the pair.
>
> B.
>
>
>
> > On Mar 29, 2018, at 9:48 PM, Ranjan Maitra
2023 Jan 16
1
Printing special characters
?s 08:31 de 16/01/2023, Jeff Newmiller escreveu:
> Use the Cairo PDF device?
>
> On January 16, 2023 12:18:48 AM PST, Dennis Fisher <fisher at plessthan.com> wrote:
>> R 4.2.2
>> OS X
>>
>> Colleagues
>>
>> A file that I have read includes strings like this:
>> "EVENT ? 30 sec"
>> When I include the string in a graphic
2011 Apr 07
1
Adding text to page margin with lattice graphics
R: 2.12.1
OS X
Colleagues
I am working with lattice graphics for the first time and I am confused by some aspects of controlling these graphics. The most pressing issue is the following:
I can print the graphics without problems with the command:
print(MYFUNCTION(SOMEOBJECT)
However, I would like to add margin text (this terminology might not apply in this setting). I am able to do so with
2003 Apr 12
1
system()
I am new to R but have used Splus for many years. When I create many
graphics in sequence in Splus/Linux, each time that I complete a
page, I send a message to my command line interface using the
following function:
FOOT <- function(PAGENO,TEXT)
{
mtext(outer=T, TEXT, side=1)
unix("cat", c(paste("Finished with page", PAGENO)),FALSE, FALSE)
2011 Apr 10
3
Adding margin text to lattice graphics
Colleagues
I am learning lattice graphics (R 2.12.2; OS X). Several days ago, I inquired about adding margin text to lattice graphics. Jim Price offered a useful reply, suggesting that I add:
page = function(page) grid.text('words', x = 0.5, y = 0.01)
to my call to the function. The entire function that he suggested was;
xyplot(1 ~ 1,
par.settings = list(layout.heights =
2018 Mar 30
0
getting all circular arrangements without accounting for order
I don't know if this is more efficient than enumerating with distinct
directions and weeding... it seems kind of heavyweight to me:
#######
library(gtools)
directionless_circular_permutations <- function( n ) {
v <- seq.int( n-1 )
ix <- combinations( n-1, 2 )
jx <- permutations( n-3, n-3 )
x <- lapply( seq.int( nrow( ix ) )
, function( i ) {
2002 Nov 15
1
Plotting in the margin
Hi,
I would like to place a line (tilted at an angle) in the margin of an R
plot. Is there any way to place such an annotation outside the plotting
area?
As an alternative, being able to plot a rotated character (the pipe, |) in
the margin would be sufficient. The problem is that mtext doesn't work
with the srt option.
As a further alternative, if I could put a legend in the margin, I
2003 Aug 15
0
Re: [R} stars graphs
I thought about that star graph again, and realized that it would be quite
a handy thing for visualizing cyclic data like time or compass direction.
Here is a cleaned up (and renamed) version to do a polar plot that starts
at the right and goes counterclockwise or a 24 hour clock plot that starts
at the top and goes clockwise. There are probably other varieties that
would be interesting.
Jim
2023 Jan 16
1
Printing special characters
>>>>> Rui Barradas
>>>>> on Mon, 16 Jan 2023 08:46:43 +0000 writes:
> ?s 08:31 de 16/01/2023, Jeff Newmiller escreveu:
>> Use the Cairo PDF device?
>>
>> On January 16, 2023 12:18:48 AM PST, Dennis Fisher
>> <fisher at plessthan.com> wrote:
>>> R 4.2.2 OS X
>>>
>>>