Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: apostrophes, quotation marks, left or right quotes?


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: apostrophes, quotation marks, left or right quotes?
Date   Mon, 25 Feb 2008 22:55:22 -0000

As I evidently said in 2005, it is unfortunate that people continue to be bitten by this. 
I am unclear why you think that email was mystifying. 

Your detailed account may help StataCorp revise the explanation in the manuals. You are right: only 
when you find the correct answer do all the accounts make complete sense. 

But unless you can show that what is quoted here from the manuals about "most keyboards" is incorrect, 
your main complaint appears to be that the manuals do not explicitly mention the kind of keyboard 
you use. Similarly, although Svend Juul gets full marks for pointing you in the right direction, the last part of his 
explanation in turn will make little sense for a very large class of users. That's the nub. Only 
an account that went through all possible keyboard variations would satisfy everyone, it seems. I also 
have in mind many countries not strongly represented in this list, but with large groups of Stata users.

Left and single quotes are needed in the use of local macros. As local macros are not 
I think usually met in many introductions to Stata, the authors of those introductions often 
don't explain how to produce the single quotes. I know that helps not at all when you need to know precisely what 
to type, but every writer on Stata struggles with what to include and what to omit. 

The plea to show these characters "as they look on the screen" will help if and only if the 
user is using a font on the screen that in this respect resembles that in the manuals. As the user 
has a choice of screen font, that cannot be guaranteed. Similarly the request to have the characters shown 
"as they look on the keyboard" cannot be satisfied, because, as most of your posting underlines, there is no 
common look across all user keyboards. 

As far as local macros are concerned, one key to understanding is that left and right quotes must be different, as otherwise 
local macros cannot be nested. Thus 'a'b'c' would otherwise be ambiguous. However, I know that in turn doesn't help much,  
as the Stata user meeting local macros the first time is unlikely to want to learn about nesting at the same time. 

Nick 
[email protected] 

P.S. I don't know what you mean by "a.m. books". You see how difficult it is to be universally intelligible! 

------------
Dirk Enzmann

How does one produce left and right single quotes as they are used in Stata?

Meanwhile, I know the answer. But because I am using Stata only 
occasionally, every now and then I encounter typical beginners' 
problems. Thus, it took me a while to find the correct answer and I 
would like to comment on the difficulties hoping that this might improve 
the situation of other beginners having the same problem.

Although I searched in "An introduction to Stata ..." by Svend Juul, 
searched the release 9 "Getting started with Stata", [U] "User's Guide", 
and [P] "Programming", and searched the internet (FAQ, statalist), it 
took me more than half an hour to find the solution (ultimately by trial 
and error).

I think the difficulty is due to a combination or an accumulation of 
three things:
(1) I am using a non-English/American keyboard (German);
(2) The letter type used in printing (especially the Stata manuals!) 
makes it impossible to decide how the correct quote should look like on 
the screen;
(3) To find the answer you have to ask the correct question, but for 
non-English speakers it is difficult to find the denotation of the signs 
as used by the Stata community.

Let us start with the latter: In German we denote the signs "Hochkomma". 
Looking this up in a standard dictionary renders "apostrophe". Searching 
the indices of the manuals or the internet for "apostrophe" does not 
help. Next, I tried "quotation mark". But alas, ... You have to look for 
"left quote" or "right quote", but how should I know if I don't know the 
answer already?

Browsing through the pages of the a.m. books did not help. Every time I 
found examples using the quotes there were no indications on how to 
produce the quotes using my keyboard. The problem: In printing the left 
quote is a curved quote similar to a small round left bracket - similar 
to "(" -, the right quote curved like a right bracket ")". However, 
there are three different single quotes I can create with my keyboard: 
One "forward" quote (similar to the forward slash "/"): |�|, one 
"backward" quote (similar to the backslash "\"): |`|, and one vertical 
quote (similar to the OR sign "|"): |'|. Why don't they use one of these 
in the printed manuals? Why? Everything would be so much easier!

Finally, after I solved the problem, I found the following exchange in 
the Stata list (thread "Help with Reading Arguments for Do-File" 
http://www.stata.com/statalist/archive/2005-11/msg00499.html ): George 
wrote "Thanks, the quotation marks were indeed the source of the 
problem. Unfortunately, the manual does not make that clear." to which 
Nick (n.j. cox) responded: "Many people have been bitten by this at 
precisely your stage, but it is wrong to blame the manuals. I find at 
[U] 18.3.1 (p.200 of Stata 9 edition) that the key difference between 
left and right single quotes is explained when local macros are introduced."

To the contrary, it *is* the manuals to blame! If you read p. 200 of the 
Stata 9 edition you find: "... we use a left single-quote (located at 
the upper left on most keyboards), ... and a right single quote (located 
under the " on the right side of most keyboards)...". This description 
does not help at all if you are using a non-English/American keyboard! 
And what is more: In printing they always use the small "(" ")" quotes 
(forward-backward-curved), so that it is really *impossible* to 
recognize the correct quote. Why make it so difficult? Why not print it 
as it should look like? Why not *print* `shortcut' ?

On the German keyboard, I have to use the "accent grave" (thus, the 
apostrophe starting on the top left) for the left single quote, and for 
the right single quote I have to use the "common" single quote (the 
vertical quote you find above the #-sign on a German keyboard ;-) , see:
http://upload.wikimedia.org/wikipedia/commons/thumb/3/36/KB_Germany.svg/400px-KB_Germany.svg.png

Ultimately, the best description I found in Svend Juuls "An Introduction 
to Stata ...":

"Hint: Producing the left single quote: In this book, the appearance of 
single quotes differs a bit from how they look on your keyboard and 
screen. Try 'help quotes' to see how they look on the screen. Keyboard 
layouts differ, and on some keyboards, the left single quote is produced 
by a dead key, meaning that nothing is produced until you hit the 
spacebar." (p. 269)

If it is impossible to print the quotes in the manuals as they look on 
the screen (and on the keyboard) - please, take over Svend Juuls 
exemplary description.

I hope that this lengthy comment helps future beginners and demystifies 
Nicks observation that "Many people have been bitten by this". Bites are 
necessary for computations but aren't helpful at all for learning.


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index