On Fri, 12 May 2017 23:39:14 -0700 Daniel Nordlund <djnordlund at gmail.com> wrote:> On 5/12/17 4:55 PM, Ranjan Maitra wrote: > > Hi, > > > > Is it possible to display double dot (umlaut) over a character such as would be possible using \ddot x in LaTeX? I can do this using tikzDevice but I wanted something simpler to point to. > > > > Here is an example of what I would like to do, but it is not quite there: > > > > require(ggplot2) > > data<-as.data.frame(c("a","b","c","a","b","c")) > > colnames(data)<-"Y" > > data$X<-c(1:6) > > data$Z<-c(1,2,3,1,2,3) > > > > ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + xlab(expression(atop(top,bold(Age~"?")))) > > > > I would like to put in a double dot over the "a" in the x-axis instead of "`". > > > > Many thanks for any suggestions and best wishes, > > Ranjan > > > > You haven't told what OS you are using, but with Windows OS, you can get > the '?' by making sure the NUMLOCK key is on, hold down the alt key and > press 0228 on the numeric keypad. > >I am sorry, I use a linux operating system. I use Fedora 25 but the student I wanted to show this uses Ubuntu, though I don't know if the distribution matters. Thanks again for your help, and best wishes, Ranjan
> On May 13, 2017, at 5:47 AM, Ranjan Maitra <maitra at email.com> wrote: > > On Fri, 12 May 2017 23:39:14 -0700 Daniel Nordlund <djnordlund at gmail.com> wrote: > >> On 5/12/17 4:55 PM, Ranjan Maitra wrote: >>> Hi, >>> >>> Is it possible to display double dot (umlaut) over a character such as would be possible using \ddot x in LaTeX? I can do this using tikzDevice but I wanted something simpler to point to. >>> >>> Here is an example of what I would like to do, but it is not quite there: >>> >>> require(ggplot2) >>> data<-as.data.frame(c("a","b","c","a","b","c")) >>> colnames(data)<-"Y" >>> data$X<-c(1:6) >>> data$Z<-c(1,2,3,1,2,3) >>> >>> ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + xlab(expression(atop(top,bold(Age~"?")))) >>> >>> I would like to put in a double dot over the "a" in the x-axis instead of "`". >>> >>> Many thanks for any suggestions and best wishes, >>> Ranjan >>> >> >> You haven't told what OS you are using, but with Windows OS, you can get >> the '?' by making sure the NUMLOCK key is on, hold down the alt key and >> press 0228 on the numeric keypad. >> >> > > I am sorry, I use a linux operating system. I use Fedora 25 but the student I wanted to show this uses Ubuntu, though I don't know if the distribution matters.On a Mac it is cmd-u followed by the vowel of your choice. Perhaps you should do a google search on the topic of getting umlauted characters for the distro of your choice? David.> > Thanks again for your help, and best wishes, > Ranjan > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.David Winsemius Alameda, CA, USA
> On 13 May 2017, at 20:10, David Winsemius <dwinsemius at comcast.net> wrote: > >> >> On May 13, 2017, at 5:47 AM, Ranjan Maitra <maitra at email.com> wrote: >> >> On Fri, 12 May 2017 23:39:14 -0700 Daniel Nordlund <djnordlund at gmail.com> wrote: >> >>> On 5/12/17 4:55 PM, Ranjan Maitra wrote: >>>> Hi, >>>> >>>> Is it possible to display double dot (umlaut) over a character such as would be possible using \ddot x in LaTeX? I can do this using tikzDevice but I wanted something simpler to point to. >>>> >>>> Here is an example of what I would like to do, but it is not quite there: >>>> >>>> require(ggplot2) >>>> data<-as.data.frame(c("a","b","c","a","b","c")) >>>> colnames(data)<-"Y" >>>> data$X<-c(1:6) >>>> data$Z<-c(1,2,3,1,2,3) >>>> >>>> ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + xlab(expression(atop(top,bold(Age~"?")))) >>>> >>>> I would like to put in a double dot over the "a" in the x-axis instead of "`". >>>> >>>> Many thanks for any suggestions and best wishes, >>>> Ranjan >>>> >>> >>> You haven't told what OS you are using, but with Windows OS, you can get >>> the '?' by making sure the NUMLOCK key is on, hold down the alt key and >>> press 0228 on the numeric keypad. >>> >>> >> >> I am sorry, I use a linux operating system. I use Fedora 25 but the student I wanted to show this uses Ubuntu, though I don't know if the distribution matters. > > On a Mac it is cmd-u followed by the vowel of your choice. Perhaps you should do a google search on the topic of getting umlauted characters for the distro of your choice? >Option u followed by vowel! If you haven't changed Modifier Keys. Berend
Rolf Turner
2017-May-14 00:54 UTC
[R] [FORGED] Re: display double dot over character in plotmath?
On 14/05/17 06:10, David Winsemius wrote:> >> On May 13, 2017, at 5:47 AM, Ranjan Maitra <maitra at email.com> wrote: >> >> On Fri, 12 May 2017 23:39:14 -0700 Daniel Nordlund <djnordlund at gmail.com> wrote: >> >>> On 5/12/17 4:55 PM, Ranjan Maitra wrote: >>>> Hi, >>>> >>>> Is it possible to display double dot (umlaut) over a character such as would be possible using \ddot x in LaTeX? I can do this using tikzDevice but I wanted something simpler to point to. >>>> >>>> Here is an example of what I would like to do, but it is not quite there: >>>> >>>> require(ggplot2) >>>> data<-as.data.frame(c("a","b","c","a","b","c")) >>>> colnames(data)<-"Y" >>>> data$X<-c(1:6) >>>> data$Z<-c(1,2,3,1,2,3) >>>> >>>> ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + xlab(expression(atop(top,bold(Age~"?")))) >>>> >>>> I would like to put in a double dot over the "a" in the x-axis instead of "`". >>>> >>>> Many thanks for any suggestions and best wishes, >>>> Ranjan >>>> >>> >>> You haven't told what OS you are using, but with Windows OS, you can get >>> the '?' by making sure the NUMLOCK key is on, hold down the alt key and >>> press 0228 on the numeric keypad. >>> >>> >> >> I am sorry, I use a linux operating system. I use Fedora 25 but the student I wanted to show this uses Ubuntu, though I don't know if the distribution matters. > > On a Mac it is cmd-u followed by the vowel of your choice. Perhaps you should do a google search on the topic of getting umlauted characters for the distro of your choice? >Well, Linux is not Mac. For which I am everlastingly thankful. I believe the following works on both Fedora and Ubuntu: (1) First add/set a "compose" key: In my current system (Ubuntu 16.04.2; Mate Desktop 1.12.1) the sequence of clicks is: System -> Control Center -> Keyboard -> Layouts -> Options -> Position of Compose key -> [e.g.] Left Win Clicking on "Left Win" inserts a tick mark in the little white box. On my keyboard the "Left Win" key is to the left of the "Alt" key, which is to the left of the space bar. It displays the (yeuchh!!!) Windoze symbol, a distorted window in black and white. This key is totally useless for anything else, so one might as well use it for the compose key. (2) Then do: <compose key> <letter> <accent>. E.g ' <compose key> a " ' gives ' ? '. Note: Do *not* hold the compose key down while pressing the other keys. Press the compose key and release it; then press "a" (nothing appears) then press ' " ' --- and bingo, ? appears. HTH cheers, Rolf Turner P. S. Of course you just need to do the "set a compose key" bizzo *once* and then it is set and works forever more. Until you change or bugger up your OS. :-) R. T. -- Technical Editor ANZJS Department of Statistics University of Auckland Phone: +64-9-373-7599 ext. 88276
Hi I just had to do something similar in windows with \"{u}. Try Unicode symbol - see ?plotmath ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + xlab(expression(atop(top,bold(Age~"\u00e4")))) Regards Duncan Duncan Mackay Department of Agronomy and Soil Science University of New England Armidale NSW 2351 Email: home: mackay at northnet.com.au -----Original Message----- From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of Ranjan Maitra Sent: Saturday, 13 May 2017 22:48 To: r-help at stat.math.ethz.ch Subject: Re: [R] display double dot over character in plotmath? On Fri, 12 May 2017 23:39:14 -0700 Daniel Nordlund <djnordlund at gmail.com> wrote:> On 5/12/17 4:55 PM, Ranjan Maitra wrote: > > Hi, > > > > Is it possible to display double dot (umlaut) over a character such aswould be possible using \ddot x in LaTeX? I can do this using tikzDevice but I wanted something simpler to point to.> > > > Here is an example of what I would like to do, but it is not quitethere:> > > > require(ggplot2) > > data<-as.data.frame(c("a","b","c","a","b","c")) > > colnames(data)<-"Y" > > data$X<-c(1:6) > > data$Z<-c(1,2,3,1,2,3) > > > > ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) +xlab(expression(atop(top,bold(Age~"?"))))> > > > I would like to put in a double dot over the "a" in the x-axis insteadof "`".> > > > Many thanks for any suggestions and best wishes, > > Ranjan > > > > You haven't told what OS you are using, but with Windows OS, you can get > the '?' by making sure the NUMLOCK key is on, hold down the alt key and > press 0228 on the numeric keypad. > >I am sorry, I use a linux operating system. I use Fedora 25 but the student I wanted to show this uses Ubuntu, though I don't know if the distribution matters. Thanks again for your help, and best wishes, Ranjan ______________________________________________ R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Thanks, Duncan! This works for the particular case and is, to my mind, a great solution! However, I was wondering: is it possible to use these double dots with another character, such as omega? I apologize for changing the question somewhat, but I did not realize earlier that there were separate codes for putting double dots over different letters and I thought that figuring out the simpler question would be enough for me to figure out the next step. Thanks again! Best wishes, Ranjan On Sun, 14 May 2017 23:57:50 +1000 Duncan Mackay <dulcalma at bigpond.com> wrote:> Hi > > I just had to do something similar in windows with \"{u}. Try Unicode symbol > - see ?plotmath > > ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + > xlab(expression(atop(top,bold(Age~"\u00e4")))) > > Regards > > Duncan > > Duncan Mackay > Department of Agronomy and Soil Science > University of New England > Armidale NSW 2351 > Email: home: mackay at northnet.com.au > > -----Original Message----- > From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of Ranjan > Maitra > Sent: Saturday, 13 May 2017 22:48 > To: r-help at stat.math.ethz.ch > Subject: Re: [R] display double dot over character in plotmath? > > On Fri, 12 May 2017 23:39:14 -0700 Daniel Nordlund <djnordlund at gmail.com> > wrote: > > > On 5/12/17 4:55 PM, Ranjan Maitra wrote: > > > Hi, > > > > > > Is it possible to display double dot (umlaut) over a character such as > would be possible using \ddot x in LaTeX? I can do this using tikzDevice but > I wanted something simpler to point to. > > > > > > Here is an example of what I would like to do, but it is not quite > there: > > > > > > require(ggplot2) > > > data<-as.data.frame(c("a","b","c","a","b","c")) > > > colnames(data)<-"Y" > > > data$X<-c(1:6) > > > data$Z<-c(1,2,3,1,2,3) > > > > > > ggplot(data, aes(x=X)) + geom_line(aes(y = Z), size=0.43) + > xlab(expression(atop(top,bold(Age~"?")))) > > > > > > I would like to put in a double dot over the "a" in the x-axis instead > of "`". > > > > > > Many thanks for any suggestions and best wishes, > > > Ranjan > > > > > > > You haven't told what OS you are using, but with Windows OS, you can get > > the '?' by making sure the NUMLOCK key is on, hold down the alt key and > > press 0228 on the numeric keypad. > > > > > > I am sorry, I use a linux operating system. I use Fedora 25 but the student > I wanted to show this uses Ubuntu, though I don't know if the distribution > matters. > > Thanks again for your help, and best wishes, > Ranjan > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. >-- Important Notice: This mailbox is ignored: e-mails are set to be deleted on receipt. Please respond to the mailing list if appropriate. For those needing to send personal or professional e-mail, please use appropriate addresses.