Next: outer() Up: MacAnova Help File Previous: number   Contents

options

Usage:
setoptions(option1:value [,option2:value ... ]) option1, option2, ...
  names of options, sets option values
getoptions(option1:T [,option2:T ... ]), option1, option2, ...  option
  names of options, retrieves option values
List of options that may be set and retrieved
  Option name          Values (* = default)
  angles               "radians"*, "degrees" or "cycles"
  batchecho            T* or F
  dumbplot             T* or F
  enableitem           "printwindow", "noprintwindow"*, "printgraph",
                       "noprintgraph"* [Windows, Motif]
  errors               integer >= 0
  findmacros           "yes"*, "silent" or "no"
  font                 quoted string ("McAOVMonaco"*) [Mac]
  fontsize             integer > 0 (9) [Mac]
  format               quoted string ("12.5g"*)
  fstats               T or F*
  height               integer >= 0 (screen size*)
  history              integer >= 0 (100*)
  inline               T or F*
  keyboard             integer >= 0 (2*) [Windows]
  labelabove           T or F*
  labelstyle           "("*, "[", "{", "<", "/", "\\"
  lines                integer >= 0 (screen size*) [same as 'height']
  matchdelay           integer >= 0 [windowed versions only]
  maxlinelen           integer >= 80
  maxwhile             integer >= 10 (1000*)
  minpvalue            0 <= number <= .001 (1e-8)
  missing              quoted string <= 20 characters ("MISSING"*)
  nsig                 0 < integer <= 20 (5*)
  plotdelay            integer > 0 (800*) [Motif]
  prompt               quoted string <= 20 characters ("Cmd> "*)
  pvals                T or F*
  quiet                T or F*
  restoredel           T* or F
  savehistry           T* or F [not limited memory DOS]
  scrollback           T or F* [windowed versions only]
  seeds                2 integers > 0 or both 0*
  tekset               CHARACTER vector of length 2 [non-Motif
                       Unix/Linux only]
  traceback            T or F*
  update               T or F [not windowed versions]
  vecread              "byfields" or "notbyfields"*
  warnings             T* or F
  wformat              quoted string ("16.9g"*)
  width                integer >= 30 (screen size*)



Keywords: control, missing values, output, random numbers, general
MacAnova has a variety of options you may set. These control or affect
output formatting, "dumb" graph size, the units used by trigonometric
functions, the string printed for MISSING values, the command line
prompt, macro creation, while loops, random number generation and the
action of save(), asciisave() and restore() (not an exhaustive list).

It may be helpful to think of options as hidden variables with LOGICAL,
CHARACTER or REAL values.  You use setoptions() to change their values
and getoptions() to retrieve their values.

You can get a brief list of options names with permissible values by
typing 'usage(options)'.

You can get an description of an individual option by typing
help(options:optionName), where optionName is the quoted name of the
option.  For example, help(options:"format") gives information on
option 'format'.

This topic lists all option that may be set.  Permissible values for
each option are in parentheses after the option name, usually with the
default value indicated.  A quoted string ("radians", for example) can
be replaced by a CHARACTER scalar and T or F can be replaced by a
LOGICAL scalar.

                      Options that may be set
angles ("radians", "degrees" or "cycles", default = "radians")
                                 Example: setoptions(angles:"cycles")
  The value specifies the angular units assumed for sin(), cos(), tan(),
  asin(), acos(), atan(), cpolar(), hpolar(), crect(), hrect() and
  unwind().  The default value is "radians".  When 'angles' is
  "degrees", 360 is equivalent to 2*PI radians; when it is "cycles", 1
  is equivalent to 2*PI radians.  See also topic 'transformations'.

batchecho (T or F, default = T)  Example: setoptions(batchecho:F)
  The value determines whether command lines that are read from a file
  by batch() are echoed to output.  True means echo; False means don't
  echo.  It is ignored when you use keyword 'echo' on batch().  See
  batch().

dumbplot (T or F, default = F)   Example: setoptions(dumbplot:F)
  The value affects the default behavior of all plotting commands
  (plot(), chplot(), lineplot(), addpoints(), boxplot(), ...).  When it
  is True, these commands make "dumb" plots, that is plots using only
  characters such as could be produced on a printer with no graphics
  capability.  When 'dumbplot' is False, high resolution graphs are
  drawn.  It is ignored when you use keyword 'dumb' on a plotting
  command.  In non-interactive mode, 'dumbplot' is always True.

  When you use spool() to save your output to disk and 'dumbplot' is
  True, copies of all your plots will be spooled.

enableitem (CHARACTER vector, default:depends on version)
                          Example: setoptions(enableitem:"printgraph")
  'enableitem' is implemented only in the Windows and Motif versions and
  was added because printing seems to cause crashes, particularly in the
  Windows version.

  The value must be a CHARACTER scalar or vector of length 2, whose
  elements must be any of "printgraph", "printwindow", "noprintgraph",
  or "noprintwindow".  Elements "noxxxx" disable printing if it is
  currently enabled.

  In both the Windows and Motif versions, the default value is
  vector("noprintwindow", "noprintgraph"), that is, both Print Window
  and Print Graph are disabled.

errors (integer >= 0)            Example: setoptions(errors:20)
  The value n is the maximum number of errors tolerated.  n = 0 means
  errors will not be counted.

  When setoptions(errors:n) is executed from a batch file, n is used
  only until entry from the keyboard is next needed.  If more than n
  errors are found while a batch file is being read, reading from all
  current batch files is terminated.

  In interactive mode, 'errors' is initially set to 0 (ignore errors).
  If it is not reset, use of batch() temporarily sets the error limit to
  1; it reverts to 0 when commands from the batch file are completed.

findmacros ("yes", "silent" or "no", default = "yes")
                                 Example: setoptions(findmacros:"no")
  The value controls the behavior of MacAnova when it encounters what
  looks like a call to a macro, but no macro with the name is defined.
  When 'findmacros' is "yes" or "silent", MacAnova searches all the
  files in pre-defined CHARACTER variable MACROFILES (see getmacros()
  and addmacrofile()) for the macro.  If a macro with that name is
  found, it is read in and then executed.  When 'findmacros' is "no", no
  search is made, resulting in an error.  When 'findmacros' is "yes", a
  warning message is printed before the search, and another one if the
  search is unsuccessful.  When 'findmacros' is "silent" or "no", no
  special messages are printed.

font (quoted string)             Example: setoptions(font:"Courier")
  The value is the name of the font used in the active command/output
  window and any additional windows that you may open from this window.
  The value should be the name of an available font such as "Courier" or
  "Monaco".  You can set both options 'font' and 'fontsize' by, for
  example, setoptions(font:"Courier 12") (see 'fontsize' below).  On a
  Macintosh the default value of 'font' is "McAOVMonaco".

  setoptions(font:"default") restores the default font and size.  See
  options 'fontsize' below.

  When you change the font, you will almost certainly want to choose a
  non-proportional font such as "Courier" or "Monaco", that is, a font
  for which all characters, including spaces, have the same width.  If
  not, columns will not line up and, in general, output will be hard to
  read.

  If you regularly prefer a font other than the default font, you might
  want to set this option in your startup file.  See topic 'customize'.

  This option is currently available only in MacAnova for Macintosh.

fontsize (integer > 0)           Example: setoptions(fontsize:18)
  The value is the size of the font used in the command/output window
  and any additional windows you may open from this window.  Option
  'fontsize' is available only in Macintosh versions, for which the
  default value is 9.

format (quoted string, default "12.5g")
                                 Example: setoptions(format:"13.6f")
  The value specifies the default format for printing.  For example, if
  the value of 'format' is "12.5g", most output will be in floating
  point form with 5 significant digits and a maximum width of 12
  characters.

  The value must be of the form "w.dg" (floating point with d
  significant digits and width w characters, including sign and
  exponent), or "w.df" (fixed point format with d digits after the
  decimal and minimum width w).  If w is omitted (for example, ".5g") it
  is taken to be d+7.  Examples are "10.5f" (fixed point with 5 decimal
  places and total width of 10) and ".15g" (floating point with 15
  significant digits and width 22).  See print() for more discussion of
  format specification.

  When setting 'format', you can put the format type specifier ('f' or
  'g') at the start of format.  For example, setoptions(format:"f10.6")
  is equivalent to setoptions(format:"10.6f").  When you retrieve the
  value using getoptions(format:T), 'f' or 'g' is always at the end.

  If you omit the width w (setoptions(format:".10g")), w = d+7 is
  assumed ("17.10g").  If you try to set the format so that w > 27 or d
  > 20, 27 and 20 are used, respectively.

  The 'g' format is a hybrid of integer format, decimal format with no
  exponent, and exponential format.  There is no purely exponential
  format available.  See topic 'number'.

fstats (T or F, default F)       Example: setoptions(fstats:T)
  The value affects the default behavior of anova(), robust() and
  fastanova().  F-statistics are printed only when the value is True.
  The value of option 'fstats' is ignored when keyword 'fstats' is used
  on these commands.

  Option 'fstats' affects manova() only when 'byvar:T' is an argument.

height (integer >= 0, default depends on screen size)
                                 Example: setoptions(height:20)
  The value is the assumed number of lines of output that will fit on
  the screen or in the command/output window.

  If nLines is the value of 'height', under Unix/Linux and DOS, whenever
  nLines-1 lines of output printed by a single command line, MacAnova
  will print "Hit RETURN to continue or q RETURN to go to next command
  line:" and then pause.  If command line editing is available, the
  message is "Press 'q' to quit, 'j' or 'n' to see next line, any other
  key to continue".

  The value of 'height' also affects the default size of stemleaf
  displays and "dumb" plots.

  When the value of 'height' is 0, counting of output lines is
  suppressed and the default size of stemleaf displays and "dumb" plots
  is 24.

  On a Macintosh, the value of 'height' may be reset when the output
  window is resized; the only effect of the value is on the number of
  lines in a "dumb" plot.

  On Unix/Linux, DOS and Windows, the value of 'height' can be
  predefined using the -l command line option.  See topic 'launching'.

  The value of option 'height' is ignored when keyword 'height' is used
  on print(), write(), matprint(), matwrite() and error() or on plotting
  functions such as plot() and boxplot() (see 'graph_keys').

  See topics stemleaf(), 'graphs'.

history (integer >= 0)           Example: setoptions(history:200)
  The value is the number of command lines that are saved and may be
  retrieved.  The default value for history is 100.  It meaningful only
  in versions that allow you to recall previous commands.  This includes
  the Macintosh, Windows and Motif versions, most Unix/Linux versions,
  and the extended memory DOS version (DJ).  See topics 'macintosh',
  'wx', 'unix', and 'dos_windows'.

  When the value of 'history' is 0, no command lines are saved.

inline (T or F, default = F)     Example: setoptions(inline:T)
  The value specifies the default method of macro expansion, in-line
  when the value is True or out-of-line when it is False.  The value of
  option 'inline' is ignored when you use keyword 'inline' on macro() or
  when you use macroread() to read a macro with 'INLINE' or 'OUTLINE' on
  its header line.  See topics macro(), macroread(), 'macros',
  macro_files.

keyboard  (integer >= 0)         Example: setoptions(keyboard:1)
  This currently has an effect only in the Windows version when using a
  non-US keyboard with an Alt Gr key.  The value determines whether
  codes generated by key combinations involving the Alt Gr key are
  recognized.  When keyboard = 2 (the default), any such key
  combinations are recognized.  When keyboard = 1, only key combinations
  associated with ASCII codes between 32 (space) and 126 (~) are
  recognized.  When keyboard = 0, no Alt Gr key combinations are
  recognized.

  Note: This value of 'keyboard' should not affect US keyboard
  configurations.  The option is provided to allow modification of
  recognition of Alt Gr combinations in case there are problems with the
  default behavior.  Other values may have special meaning in the
  future.

labelabove (T or F, default = F)   Example: setoptions(labelabove:T)
  This option specifies the placement of default coordinate labels when
  printing variables without labels (see topic 'labels').

  When the value is True, the values for the last subscript (only
  subscript in the case of vectors) are printed above the data instead
  of all the subscripts being printed in the left margin.  This has no
  effect on the printed labels of CHARACTER varables which are always at
  the left.  The effect is the same as if the variable had labels which
  were all of the form rep("@",dimsize).  The default value is False.

labelstyle ("(", "[", "{", "<", "/", "\\", default = "(")
                                 Example: setoptions(labelstyle:"[")
  This option specifies the style used in printing coordinate labels for
  unlabelled variables (see topic 'labels').  For example, when its
  value is "[", '[' and ']' are used instead of the default '(' and ')'.

lines (integer >= 0, default depends on screen size)
                                 Example: setoptions(lines:20)
  Option 'lines' is the same as option 'height' (see above).  It is
  retained for compatibility with earlier versions.

matchdelay (integer >= 0, default 400 on Windows/Motif, 20 on Macintosh)
                                 Example: setoptions(matchdelay:300)
  This sets the amount of time a matching left parenthesis or bracket is
  highlighted when you type a right parenthsis or bracket.  A value of 0
  turns off such highlighting.  In Windows and Motif, the value is in
  milliseconds; in the Macintosh version it is in ticks (1/60 second).

maxlinelen (integer >= 80, default 2000)
                                 Example: setoptions(maxlinelen:5000)
  This provides an upper limit on the length of lines from a file that
  can be completely read by vecread(), matread(), macroread() and
  read().  It also applies when reading from a CHARACTER variable using
  keyword 'string'.  If a longer line is found, you are warned that not
  everything in the line was read.

maxwhile (integer >= 10, default 1000)
                                 Example: setoptions(maxwhile:50000)
  The value is the default upper limit on the number of repetitions of a
  while(){...} loop.  When the limit is exceeded the loop is terminated
  with an error message.

minpvalue (0 <= number <= .001, default .00000001)
                                 Example: setoptions(minpvalue:5e-6)
  The value is the default lower limits for P-values to be printed as
  computed by GLM commands such as regress(), anova() or logistic().
  Values below the limit are printed as "> 1e-8", for example.  When the
  value is 0, P-values are always printed as computed.

  If the value provided has more than 2 significant digits (2.54e-6, for
  example) it is rounded (to 2.5e-6, for example) and a warning message
  is printed.

  Changing option 'minpvalue' doesn't affect values computed by cumxxx()
  functions (cumF(17.975,5,45,upper:T), for example) or by macro
  twotailt().

missing (quoted string with length <= 20 characters, default "MISSING")
                                 Example: setoptions(missing:"NA")
  The value is the default string used to print MISSING REAL or LOGICAL
  values.  For example, after setoptions(missing:"NA") any MISSING
  values will be printed as "NA" instead of the usual "MISSING".  The
  value of option 'missing' is ignored when you use keyword 'missing' on
  print() or write().  See print(), write().

  Changing option 'missing' does not affect the internal representation
  of MISSING or what gets written by matprint() and matwrite().

nsig (0 < integer <= 20, default = 5)
                                 Example: setoptions(nsig:10)
  The value is the maximum number of significant digits or decimals to
  be used in most numerical output.  Its value is linked to that of
  option 'format'.  If the value of format is "w.dg" or "w.df", then the
  value of nsig is d.  setoptions(nsig:d) is equivalent to
  'setoptions(format:"w.dg")' where d is a positive integer and w = d+7.
  See option 'format' above.

plotdelay (integer > 0, default = 800)
                                 Example: setoptions(plotdelay:1500)
  The value is the number of milliseconds to wait before displaying a
  graph window.  This is available only in the Motif version.  If
  MacAnova occasionally crashes when displaying a graph, with an error
  message about being unable to set focus, increasing the value of plot
  delay may help.  A replacement default value may be set by including
  '-plotdelay 1500', say, on the command line.  See topic 'launching'.

prompt (quoted string of no more than 20 characters, default = "Cmd> ")
                                 Example: setoptions(prompt:">> ")
  The value is printed at the start of each command line.  For example,
  after setoptions(prompt:"Next? "), each line will start with "Next? "
  instead of "Cmd> ".  In all versions except Macintosh, the initial
  value of 'prompt' can be set by command line flag -prompt (see
  'launching').

  When setoptions(prompt:Prompt) is executed in a batch file (see
  batch()), the new prompt remains in effect only until the commands in
  the file are finished.  Since a startup file (see 'customize') is
  executed as a batch file, this option cannot be usefully set in a
  startup file since the prompt is forgotten when the batch file is
  completed.

pvals (T or F, default = F)      Example: setoptions(pvals:T)
  The value affects the default behavior of all the GLM commands except
  for robust() and screen().  It affects manova() only when keywords
  'byvar' or 'fstats' are used.  When the value is True, P values for
  t-, F- and chi-squared statistics are printed; when it is False, P
  values are not printed.  The value of option 'pvals' is ignored when
  you use keyword 'pvals' as an argument to a GLM command.

quiet (T or F, default = F)       Example: setoptions(quiet:T)
  When True, all output is suppressed except for error messages and the
  input prompt (Cmd> ).  Option 'quiet' differs from other options in
  that its value is associated with a the macro currently running.

  A macro inherits the value of quiet from the prompt level, if called
  there, or from the value in a macro that calls it.

  When 'quiet' is set by setoptions() in a macro, it reverts to the
  former value when leaving the macro.

restoredel (T or F, default = T)  Example: setoptions(restoredel:F)
  The value determines whether existing variables will be deleted by
  restore().  When the value is True, they will be deleted; when it is
  False they will be deleted only when they are overwritten.  The value
  of 'restoredel' is ignored when you use keyword 'delete' on restore().

savehistry (T or F)   (note spelling)
                                 Example: setoptions(savehistry:F)
  The value determines whether a history of recent command lines will be
  saved by save() and asciisave().  When the value is True such a
  history is saved and will be automatically restored by restore(); when
  the value is False, the history is not saved.  Option 'savehistry' is
  ignored when keyword 'history' is used on save() and asciisave().  The
  default value of 'savehistry' is True except in non-interactive mode.

  'savehistry' is not available on versions such as the limited memory
  DOS version that do not maintain such a history.

scrollback (T or F, default = F) Example: setoptions(scrollback:T)
  The value determines when the command/output window will be
  automatically scrolled back to the beginning of output that is longer
  than the window can hold.  When the value is True, the window is
  scrolled back so that the most recent command line is visible.  When
  the value is False, no such scrolling takes place.  On help(), this
  default behavior can be overridden by the help() keyword 'scrollback'.
  Option 'scrollback' is available only in windowed versions (Macintosh,
  Windows, Motif).

seeds (vector of 2 integers > 0 or both 0, default = vector(0,0))
                  Example: setoptions(seeds:vector(6542821,6228765))
  The value is a REAL vector of length 2, say vector(n1,n2), where n1 >=
  0 and n2 >= 0 are integers <= 2147483399.  These values are used and
  updated by random number generators runi(), rnorm(), rbin() and
  rpoi().

  You normally set this option by setseeds() since setseeds(n1,n2) is
  equivalent to setoptions(seeds:vector(n1,n2)).

  When the value is vector(0,0), the first use of runi(), rnorm(),
  rpoi() or rbin() causes the seeds to be set to pseudo-random values
  determined from the time of day.

tekset (CHARACTER vector of length 2)
       Example: setoptions(tekset:vector("\033[?38h\0338","\033\003"))
  The value is a CHARACTER vector of length 2, say vector(ToTek,
  FromTek).  ToTek is the CHARACTER string that switches the terminal
  emulator you are using to Tektronix 4014 mode and FromTek is the
  CHARACTER string that switches out of Tektronix 4014 mode.  These are
  used before starting and after finishing a plot, and are used by
  Mouse().

  When ToTek is "", no code is sent to switch to Tektronix mode.
  Similarly, when FromTek is "", no code is sent to switch back.

  When MacAnova is running under Xterm on a Unix/Linux workstation, the
  default is as in the example above, which could also be set by
   Cmd> setoptions(tekset:vector(putascii(27,91,63,51,56,104,27,56,\
      keep:T), putascii(27,3,keep:T)))

  When MacAnova is not running under Xterm, the default is
  vector("\035\0338", "\0332") which is equivalent to
  vector(putascii(29, 27, 56, keep:T), putascii(27, 50, keep:T))

  Both defaults initialize the character size to large.

  The non-Xterm default works for Macintosh program Versaterm.  For
  other terminal emulators, this option should be initialized in a
  startup file.  See topic 'customize'.  For example, for public domain
  program Kermit 3.0 for Windows/DOS computers, your startup file might
  contain the command (not tested)
    setoptions(tekset:vector("\33[?38h\0338","\033[?38h"))

  For NCSA Telnet 2.6 for a Macintosh, use
    setoptions(tekset:vector("\033\014","\030"))

  Option 'tekset' is available only on Unix/Linux versions using
  Tetronix 4014 emulation for high resolution graphs.

traceback (T or F)               Example: setoptions(traceback:F)
  The value controls whether the chain of calling macros will be printed
  when an error occurs in a macro called by another macro.  It has no
  effect when an error does not occur in a macro.  When an error occurs
  in a macro and the value is F (the default), only the name macro is
  printed.  When the value is true the name of the macro and, when that
  macro was called in a macro, the chain of calling macros is printed.

  This option makes use of the fact that expanded macros are prefaced by
  the header '{#)#macroname'. Because some error messages append about
  50 characters of input preceding the error, you may see some calling
  macro names in short macros.  Here is an example of what this means:

  Cmd> a <- macro("q + PI"); b <- macro("a()"); c <- macro("b()")

  Cmd> setoptions(traceback:F); c() # no traceback (q not defined)
  ERROR: arithmetic with undefined operand
  UNDEF + REAL in macro a near setoptions(traceback:F); {#)#c
  {#)#b
  {#)#a
  q + PI

  Cmd> setoptions(traceback:T); c() # traceback
  ERROR: arithmetic with undefined operand
  UNDEF + REAL near setoptions(traceback:T); {#)#c
  {#)#b
  {#)#a
  q + PI
   in macro a
   called by macro b
   called by macro c

  There may be a few error messages unaffected by the value of
  'traceback'.

  See topic macro_syntax for information about writing macros.

update (T or F)                  Example: setoptions(update:F)
  The value controls whether the screen will be updated (previous
  commands and output re-printed) after a high resolution plot (True
  means update; False means don't update).  The default value of update
  is True in DOS versions and False in non-Motif Unix/Linux versions.

  Option 'update' is not available in a Windowed version (Macintosh,
  Windows, Motif).

vecread ("byfields" or "notbyfields", default = "notbyfields")
                                 Example: setoptions(vecread:"byfields")
  The value specifies the default mode for vecread() when reading REAL
  data.  When it is "notbyfields", the default value for vecread()
  keyword 'byfields' is False; when it is "byfields" the default value
  of 'byfields' is True.

  Option 'vecread' is ignored by vecread() when it is reading CHARACTER
  data.

warnings (T or F, default = T)   Example: setoptions(warnings:F)
  The value controls whether MacAnova will suppress the printing of
  warning messages (those that start with "WARNING:").  Such lines will
  be printed only when the value of 'warnings' is True.  Setting
  'warnings' to False can be useful when doing arithmetic with and
  transformations of vectors or matrices with missing data.  However,
  since many warning messages are quite important, it should be used
  with caution.  When you change 'warnings' to False, you should use
  setoptions(warnings:T) to restore the usual behavior as soon as
  possible.

wformat (quoted string, default = "16.9g")
                                 Example: setoptions(wformat:".17g")
  The value specifies the default format for the commands write() and
  matwrite().  For example, if the value is "16.9g", most output will be
  in floating point form with 9 significant digits and a maximum width
  of 16 characters.

  See option 'format' above for more information about permissible
  values.

width (integer >= 30, default depends on screen width)
                                 Example: setoptions(width:65)
  The value is the number of characters assumed to fit on a line on the
  screen or in the window.  This number, together with the current
  formatting options, determines how many items are printed per line and
  the width of "dumb" plots.

  The value of option 'width' is ignored when keyword 'width' is used on
  print(), write(), matprint(), matwrite() and error() and on plotting
  functions such as plot() and boxplot() (see 'graph_keys').

  On Unix/Linux and DOS 'width' may be initialized by the -w command
  line flag (see topic 'launching').  On a Macintosh, 'width' may be
  reset when the output window is resized.

  Some output does not respect this limit.


Gary Oehlert 2003-01-15