This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: "R" help leaves out lines of text


Marco Atzeri <marco.atzeri <at> gmail.com> writes:
>> I am ramping up on the R statistical analysis environment.  I find
>> that the help leaves out entire lines of text.  The pager is
>> /usr/lib/R/bin/pager.  I changed it to /bin/less, but I see the
>> same symptom.  The problem shows up both in xterm and mintty.  The
>> computer is in a locked down environment, so a straight update of
>> cygwin packages is not an option.  From the R forum, the problem
>> might be due to improper handling of line endings by the R port to
>> cygwin.
>>
>> Is there anything further I can try to circumvent the problem?
>>
>> My version info is:
>>
>>     64-bit Cygwin DLL version 1.7.28
>>     R version 3.0.1-1
>>
> 
> Are the input files Unix style or DOS style ?
> Can you give an example to replicate your finding ?
> 
> I can that test than if the last R-3.1.3-1 package behaves correctly
> or not. R-3.0.1-1 package is almost 2 years old.

I can't actually find the help files; I suspect that they are not just
plain text.  I tried looking for html versions of the help pages by
ferruting through the R.home() subtree.  Haven't found them so far.
There are package pages in subdirectories <package>/html/00Index.html,
but they just contain links to html files that don't reside in my
R.home() subtree.  There are also subdirectories <package>/help, but
they contain pages that I don't recognize (*.rds, *.rdb, *.rdx).

As an example, I've attached the output from ?help at the very end
below.  My current workaround is to use the following in my
~/.Rprofile, which forces the help to a browser:

   options(browser="cygstart")
   options(help_type="html")

Here's the bad result from help(help,help_type="text"):


 help                   package:utils                   R Documentation

<....multiple blank lines...>

Documentation

<....multiple blank lines...>

Description:

<....multiple blank lines...>

Usage:

<....multiple blank lines...>

     help(topic, package = NULL, lib.loc = NULL,
          verbose = getOption("verbose"),
          try.all.packages = getOption("help.try.all.packages"),
          help_type = getOption("help_type"))

<....multiple blank lines...>

Arguments:

<....multiple blank lines...>

lines 1-23------------------------- ("less" prompt)

<....multiple blank lines...>

Details:

<....multiple blank lines...>

     The following types of help are available:

<....multiple blank lines...>

Plain text help

<....multiple blank lines...>

If a package is specified, (text or, in interactive use only, HTML)
          information on the package, including hints/links to suitable
          help topics.

<....multiple blank lines...>

lines 24-46------------------------- ("less" prompt)

<....multiple blank lines...>

Offline help:

<....multiple blank lines...>

Note:

<....multiple blank lines...>

References:

<....multiple blank lines...>

     Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) _The New S
     Language_.  Wadsworth & Brooks/Cole.

<....multiple blank lines...>

See Also:

<....multiple blank lines...>

Examples:

<....multiple blank lines...>

     help()
     help(help)              # the same

<....multiple blank lines...>

lines 47-69------------------------- ("less" prompt)
      help(lapply)

<....multiple blank lines...>

     help("for")             # or ?"for", but quotes/backticks are needed

<....multiple blank lines...>

     try({# requires working TeX installation:
      help(dgamma, help_type = "pdf")
      ## -> nicely formatted pdf -- including math formula -- for help
(dgamma):
      system2(getOption("pdfviewer"), "dgamma.pdf", wait = FALSE)
     })

<....multiple blank lines...>

     help(package = "splines") # get help even when package is not loaded

<....multiple blank lines...>

     topi <- "women"
     help(topi)

<....multiple blank lines...>

     try(help("bs", try.all.packages = FALSE)) # reports not found (an 
error)
     help("bs", try.all.packages = TRUE)       # reports can be found
                                               # in package 'splines'

<....multiple blank lines...>

     ## For programmatic use:
     topic <- "family"; pkg_ref <- "stats"
     help((topic), (pkg_ref))

<....multiple blank lines...>

lines 70-92------------------------- ("less" prompt)

<....multiple blank lines...>

     help("for")             # or ?"for", but quotes/backticks are needed

<....multiple blank lines...>

     try({# requires working TeX installation:
      help(dgamma, help_type = "pdf")
      ## -> nicely formatted pdf -- including math formula -- for help
(dgamma):
      system2(getOption("pdfviewer"), "dgamma.pdf", wait = FALSE)
     })

<....multiple blank lines...>

     help(package = "splines") # get help even when package is not loaded

<....multiple blank lines...>

     topi <- "women"
     help(topi)

<....multiple blank lines...>

     try(help("bs", try.all.packages = FALSE)) # reports not found (an 
error)
     help("bs", try.all.packages = TRUE)       # reports can be found
                                               # in package 'splines'

<....multiple blank lines...>

     ## For programmatic use:
     topic <- "family"; pkg_ref <- "stats"
     help((topic), (pkg_ref))

<....multiple blank lines...>

lines 71-93/93 (END)------------------------- ("less" prompt)


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]