[R] roxygen2 question

Witold E Wolski wewolski at gmail.com
Wed May 14 17:51:21 CEST 2014


How to document S3Methods with roxygen so that I have only 1 entry in
the package documentation page per S3Method.

In the package documentation page they show up than as follows

read2msExperiment read 2 feature alginer long format and generate an
msexperiment
read2msExperiment.data.frame convert data.frame 2 msexperiment
read2msExperiment.default read 2 feature alginer long format and
generate an msexperiment


I did alias read2msExperiment in the documentation of
read2msExperiment.default but this only helps that read2msExperiment
points to the documentation of read2msExperiment.default.

What I would like to have is one entry in the package documentation
page for all s3Methods:

This is my roxygen code at the moment.


#' @export
read2msExperiment=function(obj,...){
  UseMethod('read2msExperiment')
}
#' read 2 feature alginer long format and generate an msexperiment
#' @aliases read2msExperiment
#' @param filename filename to read (can't be compressed)
#' @return msexperiment
#' @export
read2msExperiment.default=function(filename){
  print("read2msExperiment.default")
  aligtable=fread(filename)
  data = convertLF2Wideformat(aligtable)
  data = convert2msExperiment(data)
  return(data)
}





-- 
Witold Eryk Wolski



More information about the R-help mailing list